470,612 Members | 2,522 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,612 developers. It's quick & easy.

Webservice works on the browser but not from C# app

I have a HelloWorld webservice that works on my IE browser. But, when
I add a webreference to it and call the HelloWorld method from my
WindowsFormsApp (return in C#), I get error messages. The error
messages differ depending on when I restart my machine.

RIGHT AFTER RESTART:

'WindowsApplication1.exe': Loaded 'oevrvyg9', No symbols loaded.
A first chance exception of type 'System.NullReferenceException'
occurred in system.dll

Additional information: Object reference not set to an instance of an
object.

A first chance exception of type 'System.Net.Sockets.SocketException'
occurred in system.dll

Additional information: An established connection was aborted by the
software in your host machine

A first chance exception of type 'System.IO.IOException' occurred in
system.dll

Additional information: Unable to read data from the transport
connection.

A first chance exception of type 'System.Net.WebException' occurred in
system.dll

Additional information: The underlying connection was closed: An
unexpected error occurred on a receive.

A first chance exception of type 'System.Net.WebException' occurred in
system.web.services.dll

Additional information: The underlying connection was closed: An
unexpected error occurred on a receive.

at System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebRequest
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
at WindowsApplication1.localhost.Service1.HelloWorld( ) in
D:\WindowsApplication1\Web References\localhost\Reference.cs:line 37
at WindowsApplication1.Form1.cmdBegin_Click(Object sender,
EventArgs e) in d:\windowsapplication1\form1.cs:line 97

SECOND TIME:

Additional information: The operation has timed-out.

A first chance exception of type 'System.Net.WebException' occurred in
system.dll

Additional information: The operation has timed-out.

A first chance exception of type 'System.Net.WebException' occurred in
system.web.services.dll

Additional information: The operation has timed-out.

at System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebRequest
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
at WindowsApplication1.localhost.Service1.HelloWorld( ) in
D:\WindowsApplication1\Web References\localhost\Reference.cs:line 37
at WindowsApplication1.Form1.cmdBegin_Click(Object sender,
EventArgs e) in d:\windowsapplication1\form1.cs:line 97
Nov 21 '05 #1
3 9360
I think you need to debug the web method code to see where you are
generating the null reference exception.

I hope this helps

Dan Rogers
Microsoft Corporation
--------------------
From: ks****@gmail.com (subha)
Newsgroups: microsoft.public.dotnet.framework.webservices
Subject: Webservice works on the browser but not from C# app
Date: 12 Nov 2004 09:32:56 -0800
Organization: http://groups.google.com
Lines: 73
Message-ID: <72**************************@posting.google.com >
NNTP-Posting-Host: 163.188.94.164
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
X-Trace: posting.google.com 1100280776 1539 127.0.0.1 (12 Nov 2004 17:32:56
GMT)
X-Complaints-To: gr**********@google.com
NNTP-Posting-Date: Fri, 12 Nov 2004 17:32:56 +0000 (UTC)
Path:
cpmsftngxa10.phx.gbl!TK2MSFTNGXA03.phx.gbl!TK2MSFT NGP08.phx.gbl!newsfeed00.s
ul.t-online.de!t-online.de!newsfeed.icl.net!proxad.net!216.239.36.1 34.MISMAT
CH!postnews.google.com!not-for-mail
Xref: cpmsftngxa10.phx.gbl
microsoft.public.dotnet.framework.webservices:7405
X-Tomcat-NG: microsoft.public.dotnet.framework.webservices

I have a HelloWorld webservice that works on my IE browser. But, when
I add a webreference to it and call the HelloWorld method from my
WindowsFormsApp (return in C#), I get error messages. The error
messages differ depending on when I restart my machine.

RIGHT AFTER RESTART:

'WindowsApplication1.exe': Loaded 'oevrvyg9', No symbols loaded.
A first chance exception of type 'System.NullReferenceException'
occurred in system.dll

Additional information: Object reference not set to an instance of an
object.

A first chance exception of type 'System.Net.Sockets.SocketException'
occurred in system.dll

Additional information: An established connection was aborted by the
software in your host machine

A first chance exception of type 'System.IO.IOException' occurred in
system.dll

Additional information: Unable to read data from the transport
connection.

A first chance exception of type 'System.Net.WebException' occurred in
system.dll

Additional information: The underlying connection was closed: An
unexpected error occurred on a receive.

A first chance exception of type 'System.Net.WebException' occurred in
system.web.services.dll

Additional information: The underlying connection was closed: An
unexpected error occurred on a receive.

at
System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebReques
t
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
at WindowsApplication1.localhost.Service1.HelloWorld( ) in
D:\WindowsApplication1\Web References\localhost\Reference.cs:line 37
at WindowsApplication1.Form1.cmdBegin_Click(Object sender,
EventArgs e) in d:\windowsapplication1\form1.cs:line 97

SECOND TIME:

Additional information: The operation has timed-out.

A first chance exception of type 'System.Net.WebException' occurred in
system.dll

Additional information: The operation has timed-out.

A first chance exception of type 'System.Net.WebException' occurred in
system.web.services.dll

Additional information: The operation has timed-out.

at
System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebReques
t
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
at WindowsApplication1.localhost.Service1.HelloWorld( ) in
D:\WindowsApplication1\Web References\localhost\Reference.cs:line 37
at WindowsApplication1.Form1.cmdBegin_Click(Object sender,
EventArgs e) in d:\windowsapplication1\form1.cs:line 97

Nov 23 '05 #2
Dan,

Thanks for the mail. An actual person from Microsoft Tech support found that
one of my installed applications was interfering with IIS for some reason.
When I uninstalled that application and restarted, my application started
reaching the webservice.

He found this by generating hang dumps and analyzing the hang dumps. I
wonder how others having similar problems would have found this.

Regards
Subha

"Dan Rogers" wrote:
I think you need to debug the web method code to see where you are
generating the null reference exception.

I hope this helps

Dan Rogers
Microsoft Corporation
--------------------
From: ks****@gmail.com (subha)
Newsgroups: microsoft.public.dotnet.framework.webservices
Subject: Webservice works on the browser but not from C# app
Date: 12 Nov 2004 09:32:56 -0800
Organization: http://groups.google.com
Lines: 73
Message-ID: <72**************************@posting.google.com >
NNTP-Posting-Host: 163.188.94.164
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
X-Trace: posting.google.com 1100280776 1539 127.0.0.1 (12 Nov 2004 17:32:56
GMT)
X-Complaints-To: gr**********@google.com
NNTP-Posting-Date: Fri, 12 Nov 2004 17:32:56 +0000 (UTC)
Path:
cpmsftngxa10.phx.gbl!TK2MSFTNGXA03.phx.gbl!TK2MSFT NGP08.phx.gbl!newsfeed00.s
ul.t-online.de!t-online.de!newsfeed.icl.net!proxad.net!216.239.36.1 34.MISMAT
CH!postnews.google.com!not-for-mail
Xref: cpmsftngxa10.phx.gbl
microsoft.public.dotnet.framework.webservices:7405
X-Tomcat-NG: microsoft.public.dotnet.framework.webservices

I have a HelloWorld webservice that works on my IE browser. But, when
I add a webreference to it and call the HelloWorld method from my
WindowsFormsApp (return in C#), I get error messages. The error
messages differ depending on when I restart my machine.

RIGHT AFTER RESTART:

'WindowsApplication1.exe': Loaded 'oevrvyg9', No symbols loaded.
A first chance exception of type 'System.NullReferenceException'
occurred in system.dll

Additional information: Object reference not set to an instance of an
object.

A first chance exception of type 'System.Net.Sockets.SocketException'
occurred in system.dll

Additional information: An established connection was aborted by the
software in your host machine

A first chance exception of type 'System.IO.IOException' occurred in
system.dll

Additional information: Unable to read data from the transport
connection.

A first chance exception of type 'System.Net.WebException' occurred in
system.dll

Additional information: The underlying connection was closed: An
unexpected error occurred on a receive.

A first chance exception of type 'System.Net.WebException' occurred in
system.web.services.dll

Additional information: The underlying connection was closed: An
unexpected error occurred on a receive.

at
System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebReques
t
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
at WindowsApplication1.localhost.Service1.HelloWorld( ) in
D:\WindowsApplication1\Web References\localhost\Reference.cs:line 37
at WindowsApplication1.Form1.cmdBegin_Click(Object sender,
EventArgs e) in d:\windowsapplication1\form1.cs:line 97

SECOND TIME:

Additional information: The operation has timed-out.

A first chance exception of type 'System.Net.WebException' occurred in
system.dll

Additional information: The operation has timed-out.

A first chance exception of type 'System.Net.WebException' occurred in
system.web.services.dll

Additional information: The operation has timed-out.

at
System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebReques
t
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
at WindowsApplication1.localhost.Service1.HelloWorld( ) in
D:\WindowsApplication1\Web References\localhost\Reference.cs:line 37
at WindowsApplication1.Form1.cmdBegin_Click(Object sender,
EventArgs e) in d:\windowsapplication1\form1.cs:line 97

Nov 23 '05 #3
Hi Subha,

Which application was interfering?

Dan
--------------------
Thread-Topic: Webservice works on the browser but not from C# app
thread-index: AcTb+zOGv0iFZBl6SFisQkhjAOnqVQ==
X-WBNR-Posting-Host: 68.91.114.114
From: "=?Utf-8?B?c3ViaGE=?=" <su***@discussions.microsoft.com>
References: <72**************************@posting.google.com >
<h7**************@cpmsftngxa10.phx.gbl>
Subject: RE: Webservice works on the browser but not from C# app
Date: Mon, 6 Dec 2004 17:22:22 -0800
Lines: 125
Message-ID: <D3**********************************@microsoft.co m>
MIME-Version: 1.0
Content-Type: text/plain;
charset="Utf-8"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Content-Class: urn:content-classes:message
Importance: normal
Priority: normal
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
Newsgroups: microsoft.public.dotnet.framework.webservices
NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.1.29
Path: cpmsftngxa10.phx.gbl!TK2MSFTNGXA03.phx.gbl
Xref: cpmsftngxa10.phx.gbl
microsoft.public.dotnet.framework.webservices:7927
X-Tomcat-NG: microsoft.public.dotnet.framework.webservices

Dan,

Thanks for the mail. An actual person from Microsoft Tech support found
that
one of my installed applications was interfering with IIS for some reason.
When I uninstalled that application and restarted, my application started
reaching the webservice.

He found this by generating hang dumps and analyzing the hang dumps. I
wonder how others having similar problems would have found this.

Regards
Subha

"Dan Rogers" wrote:
I think you need to debug the web method code to see where you are
generating the null reference exception.

I hope this helps

Dan Rogers
Microsoft Corporation
--------------------
From: ks****@gmail.com (subha)
Newsgroups: microsoft.public.dotnet.framework.webservices
Subject: Webservice works on the browser but not from C# app
Date: 12 Nov 2004 09:32:56 -0800
Organization: http://groups.google.com
Lines: 73
Message-ID: <72**************************@posting.google.com >
NNTP-Posting-Host: 163.188.94.164
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
X-Trace: posting.google.com 1100280776 1539 127.0.0.1 (12 Nov 2004 17:32:56 GMT)
X-Complaints-To: gr**********@google.com
NNTP-Posting-Date: Fri, 12 Nov 2004 17:32:56 +0000 (UTC)
Path:
cpmsftngxa10.phx.gbl!TK2MSFTNGXA03.phx.gbl!TK2MSFT NGP08.phx.gbl!newsfeed00.s ul.t-online.de!t-online.de!newsfeed.icl.net!proxad.net!216.239.36.1 34.MISMAT CH!postnews.google.com!not-for-mail
Xref: cpmsftngxa10.phx.gbl
microsoft.public.dotnet.framework.webservices:7405
X-Tomcat-NG: microsoft.public.dotnet.framework.webservices

I have a HelloWorld webservice that works on my IE browser. But, when
I add a webreference to it and call the HelloWorld method from my
WindowsFormsApp (return in C#), I get error messages. The error
messages differ depending on when I restart my machine.

RIGHT AFTER RESTART:

'WindowsApplication1.exe': Loaded 'oevrvyg9', No symbols loaded.
A first chance exception of type 'System.NullReferenceException'
occurred in system.dll

Additional information: Object reference not set to an instance of an
object.

A first chance exception of type 'System.Net.Sockets.SocketException'
occurred in system.dll

Additional information: An established connection was aborted by the
software in your host machine

A first chance exception of type 'System.IO.IOException' occurred in
system.dll

Additional information: Unable to read data from the transport
connection.

A first chance exception of type 'System.Net.WebException' occurred in
system.dll

Additional information: The underlying connection was closed: An
unexpected error occurred on a receive.

A first chance exception of type 'System.Net.WebException' occurred in
system.web.services.dll

Additional information: The underlying connection was closed: An
unexpected error occurred on a receive.

at
System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebReques t
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
at WindowsApplication1.localhost.Service1.HelloWorld( ) in
D:\WindowsApplication1\Web References\localhost\Reference.cs:line 37
at WindowsApplication1.Form1.cmdBegin_Click(Object sender,
EventArgs e) in d:\windowsapplication1\form1.cs:line 97

SECOND TIME:

Additional information: The operation has timed-out.

A first chance exception of type 'System.Net.WebException' occurred in
system.dll

Additional information: The operation has timed-out.

A first chance exception of type 'System.Net.WebException' occurred in
system.web.services.dll

Additional information: The operation has timed-out.

at
System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebReques t
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
at WindowsApplication1.localhost.Service1.HelloWorld( ) in
D:\WindowsApplication1\Web References\localhost\Reference.cs:line 37
at WindowsApplication1.Form1.cmdBegin_Click(Object sender,
EventArgs e) in d:\windowsapplication1\form1.cs:line 97


Nov 23 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Ravi | last post: by
6 posts views Thread by Davie | last post: by
1 post views Thread by Erik | last post: by
6 posts views Thread by Jan | last post: by
2 posts views Thread by Lumen | last post: by
7 posts views Thread by Robbert van Geldrop | last post: by
3 posts views Thread by tim.cavins | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.