473,508 Members | 2,475 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Why no excpetion returned to browser when thrown from web service

Team,
Hoping you can help. I have a web service I develop. In the code behind,
we throw an exception in some cases. When I run the webservice on my PC, the
exception is displayed in my browser.

However, when I run a test on this web service on a server it has been
deployed to no such expcetion returns to the screen - just the generic Page
Not Found error with HTTP 500 - Internal Server Error.

I have ran in debug & release mode on my pc. In both cases, I get the
exception message returned to browser. So it isn't the mode. Now I'm
guessing it is either IIS or IE setting. Who can help?

Much thanks,
Tim
Nov 23 '05 #1
6 1882
By default. The detail error message will only be shown when you running on
local server. In your case, if you try to access your deployment server from
another machine, you can only see a 500 Error, unless you test on the
deployment server.

If you want the remote request can see the detail error page, you can switch
it on in your web.config. I can't remember which property to change. but you
look under the <debug> section or look for more information on debugging web
service from msdn library.
--
Can You?You Can.
"Tim Reynolds" wrote:
Team,
Hoping you can help. I have a web service I develop. In the code behind,
we throw an exception in some cases. When I run the webservice on my PC, the
exception is displayed in my browser.

However, when I run a test on this web service on a server it has been
deployed to no such expcetion returns to the screen - just the generic Page
Not Found error with HTTP 500 - Internal Server Error.

I have ran in debug & release mode on my pc. In both cases, I get the
exception message returned to browser. So it isn't the mode. Now I'm
guessing it is either IIS or IE setting. Who can help?

Much thanks,
Tim

Nov 23 '05 #2
By default. The detail error message will only be shown when you running on
local server. In your case, if you try to access your deployment server from
another machine, you can only see a 500 Error, unless you test on the
deployment server.

If you want the remote request can see the detail error page, you can switch
it on in your web.config. I can't remember which property to change. but you
look under the <debug> section or look for more information on debugging web
service from msdn library.
--
Can You?You Can.
"Tim Reynolds" wrote:
Team,
Hoping you can help. I have a web service I develop. In the code behind,
we throw an exception in some cases. When I run the webservice on my PC, the
exception is displayed in my browser.

However, when I run a test on this web service on a server it has been
deployed to no such expcetion returns to the screen - just the generic Page
Not Found error with HTTP 500 - Internal Server Error.

I have ran in debug & release mode on my pc. In both cases, I get the
exception message returned to browser. So it isn't the mode. Now I'm
guessing it is either IIS or IE setting. Who can help?

Much thanks,
Tim

Nov 23 '05 #3
Hello
Please make the following change
<customErrors mode="RemoteOnly" />
in the web.config file so that you can see the exact error message on the
browser on your server

"BillyLiu007" wrote:
By default. The detail error message will only be shown when you running on
local server. In your case, if you try to access your deployment server from
another machine, you can only see a 500 Error, unless you test on the
deployment server.

If you want the remote request can see the detail error page, you can switch
it on in your web.config. I can't remember which property to change. but you
look under the <debug> section or look for more information on debugging web
service from msdn library.
--
Can You?You Can.
"Tim Reynolds" wrote:
Team,
Hoping you can help. I have a web service I develop. In the code behind,
we throw an exception in some cases. When I run the webservice on my PC, the
exception is displayed in my browser.

However, when I run a test on this web service on a server it has been
deployed to no such expcetion returns to the screen - just the generic Page
Not Found error with HTTP 500 - Internal Server Error.

I have ran in debug & release mode on my pc. In both cases, I get the
exception message returned to browser. So it isn't the mode. Now I'm
guessing it is either IIS or IE setting. Who can help?

Much thanks,
Tim

Nov 23 '05 #4
Hello
Please make the following change
<customErrors mode="RemoteOnly" />
in the web.config file so that you can see the exact error message on the
browser on your server

"BillyLiu007" wrote:
By default. The detail error message will only be shown when you running on
local server. In your case, if you try to access your deployment server from
another machine, you can only see a 500 Error, unless you test on the
deployment server.

If you want the remote request can see the detail error page, you can switch
it on in your web.config. I can't remember which property to change. but you
look under the <debug> section or look for more information on debugging web
service from msdn library.
--
Can You?You Can.
"Tim Reynolds" wrote:
Team,
Hoping you can help. I have a web service I develop. In the code behind,
we throw an exception in some cases. When I run the webservice on my PC, the
exception is displayed in my browser.

However, when I run a test on this web service on a server it has been
deployed to no such expcetion returns to the screen - just the generic Page
Not Found error with HTTP 500 - Internal Server Error.

I have ran in debug & release mode on my pc. In both cases, I get the
exception message returned to browser. So it isn't the mode. Now I'm
guessing it is either IIS or IE setting. Who can help?

Much thanks,
Tim

Nov 23 '05 #5
Thanks - but I tried <customErrors mode="RemoteOnly" /> in the web.config on
the remote server. I tested the web service 2 ways 1) logged in to the
remote server via remote desktop & 2) from my pc - in both cases - same
result as previous - the Page Cannot Be displayed and the HTTP 500 - Internal
server error. It doesn't seem to matter if I am testing this web service
from the server directly or from my PC - either way the same results.

However, you pointed me in the right direction. I then tried "Off' instead
of remote only and achieved the desired result - finally my exception
displayed. Thanks for the tip.

Tim

"Deepak" wrote:
Hello
Please make the following change
<customErrors mode="RemoteOnly" />
in the web.config file so that you can see the exact error message on the
browser on your server

"BillyLiu007" wrote:
By default. The detail error message will only be shown when you running on
local server. In your case, if you try to access your deployment server from
another machine, you can only see a 500 Error, unless you test on the
deployment server.

If you want the remote request can see the detail error page, you can switch
it on in your web.config. I can't remember which property to change. but you
look under the <debug> section or look for more information on debugging web
service from msdn library.
--
Can You?You Can.
"Tim Reynolds" wrote:
Team,
Hoping you can help. I have a web service I develop. In the code behind,
we throw an exception in some cases. When I run the webservice on my PC, the
exception is displayed in my browser.

However, when I run a test on this web service on a server it has been
deployed to no such expcetion returns to the screen - just the generic Page
Not Found error with HTTP 500 - Internal Server Error.

I have ran in debug & release mode on my pc. In both cases, I get the
exception message returned to browser. So it isn't the mode. Now I'm
guessing it is either IIS or IE setting. Who can help?

Much thanks,
Tim

Nov 23 '05 #6
Thanks - but I tried <customErrors mode="RemoteOnly" /> in the web.config on
the remote server. I tested the web service 2 ways 1) logged in to the
remote server via remote desktop & 2) from my pc - in both cases - same
result as previous - the Page Cannot Be displayed and the HTTP 500 - Internal
server error. It doesn't seem to matter if I am testing this web service
from the server directly or from my PC - either way the same results.

However, you pointed me in the right direction. I then tried "Off' instead
of remote only and achieved the desired result - finally my exception
displayed. Thanks for the tip.

Tim

"Deepak" wrote:
Hello
Please make the following change
<customErrors mode="RemoteOnly" />
in the web.config file so that you can see the exact error message on the
browser on your server

"BillyLiu007" wrote:
By default. The detail error message will only be shown when you running on
local server. In your case, if you try to access your deployment server from
another machine, you can only see a 500 Error, unless you test on the
deployment server.

If you want the remote request can see the detail error page, you can switch
it on in your web.config. I can't remember which property to change. but you
look under the <debug> section or look for more information on debugging web
service from msdn library.
--
Can You?You Can.
"Tim Reynolds" wrote:
Team,
Hoping you can help. I have a web service I develop. In the code behind,
we throw an exception in some cases. When I run the webservice on my PC, the
exception is displayed in my browser.

However, when I run a test on this web service on a server it has been
deployed to no such expcetion returns to the screen - just the generic Page
Not Found error with HTTP 500 - Internal Server Error.

I have ran in debug & release mode on my pc. In both cases, I get the
exception message returned to browser. So it isn't the mode. Now I'm
guessing it is either IIS or IE setting. Who can help?

Much thanks,
Tim

Nov 23 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
7194
by: BLH | last post by:
Hi, I am using a 3rd party product that returns XML when calling its exe through a URL. For instance, the following URL calls this exe in Internet Explorer and returns valid, well formed XML...
2
8194
by: obeOnline | last post by:
I'm getting the following error... System.Net.HttpWebRequest.CheckFinalStatus() +676 System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult) +139...
0
295
by: Tim Reynolds | last post by:
Team, Hoping you can help. I have a web service I develop. In the code behind, we throw an exception in some cases. When I run the webservice on my PC, the exception is displayed in my browser....
20
4442
by: Tim Reynolds | last post by:
Team, I am developing a web service. In testing in on my enw PC, I am expecting to see exceptions thrown appear on my browser. Instead I am getting an HTTP 500 Internal Server Error page and I am...
2
2774
by: Jim S | last post by:
I have a .net framework 2.0 client (Pocket PC) and a .net 2.0 webservice that communicate on the same LAN. The Pocket PC has no problem consuming strings returned from the web service methoeds but...
9
12000
by: jsoques | last post by:
Hello, I created a Web Service using .Net 2.0 that has a function that returns a DataTable. I can test the function from the web page when I access the .asmx from a browser on localhost and it...
4
2968
by: =?Utf-8?B?R3JlZw==?= | last post by:
I am a newbie to WCF so please forgive if this is an obvious question. I have the following. (Service contract) IEmployee public interface IEmployee { List<EmployeeGetEmployeeByID(string...
3
1340
by: John Skandar | last post by:
I've found a free WebService on the net for a currency converter and have created a class to use it with the WSDL tool. I call the WebService method asynchronously: ...
1
1720
Frinavale
by: Frinavale | last post by:
I'm having a problem that I cannot seem to debug. FireFox's FireBug extension is indicating that there is an error being thrown, but I have no idea which window caused the error to be thrown. I...
0
7231
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7133
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7405
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7066
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7504
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5643
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3198
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1568
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
435
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.