By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,543 Members | 2,037 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,543 IT Pros & Developers. It's quick & easy.

Error looking up webservice, in the test mode

P: n/a
Hi,
I am testing with Visual studio 2005, web projects.

Situation:
I have one solution with two web projects, created as file system projects.
(I am tesing using the built in server, not IIS)
First project is a webService.
Second consumes the webservices by the first.
Problem/Error:
Often when I run the second, to call the websrvice from the first, following
error happens.
When I just re-run, no problems.
It fails trying to call the webservice of the second.

How do I stop this from happenning?
(seems like some session is expiring, and the subsequent call fails (have to
constantly test, while changing aspx))
---- ERROR ----------------------------
An established connection was aborted by the software in your host machine

Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.Net.Sockets.SocketException: An established
connection was aborted by the software in your host machine

Thanks
Nalaka
Nov 19 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Hi Nalaka,

Welcome to ASPNET newsgroup.
From your description, you've build a asp.net 2.0 web app and a webservice
project through the whidbey vs.net IDE and choose the file system projects.
When you call the webservice from the web app, sometimes there'll occur
error for lookingup webservice, yes?

Based on my experience, this problem is likely caused by the webservice is
built in a file system based project. For file system based project, the
VS.NET IDE will use the internal webserver to host it , however since the
internal websever may start on a random port each time it start (on demand)
and the port may vary between the different time you start your webservice(
for example, close the project and open/run after long time). So when you
call it in your asp.net web project, the webservice's instance may not
started yet or started on a different port from the one your web app access
last time.

To avoid this, I suggest you run your webservice asmx page first (through
browser ) so as to make it alive on a certain port (in the internal
webserver). Then, adjust the web Reference's URL in your web project so as
to make sure the webservice can be accessed correctly. In addition, if
there's IIS installed on your dev machine, you can also consider deploy the
webservice project to the IIS server and access the webservice from webapp
through the IIS project( the URL will not vary in different time)

Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)


--------------------
| From: "Nalaka" <na******@nospam.nospam>
| Subject: Error looking up webservice, in the test mode
| Date: Thu, 28 Jul 2005 11:41:54 -0700
| Lines: 37
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
| X-RFC2646: Format=Flowed; Original
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
| Message-ID: <Ov**************@TK2MSFTNGP15.phx.gbl>
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| NNTP-Posting-Host: m181-9.bctransit.bc.ca 199.60.181.9
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFT NGP15.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet:115007
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| Hi,
| I am testing with Visual studio 2005, web projects.
|
| Situation:
| I have one solution with two web projects, created as file system
projects.
| (I am tesing using the built in server, not IIS)
| First project is a webService.
| Second consumes the webservices by the first.
|
|
| Problem/Error:
| Often when I run the second, to call the websrvice from the first,
following
| error happens.
| When I just re-run, no problems.
| It fails trying to call the webservice of the second.
|
| How do I stop this from happenning?
| (seems like some session is expiring, and the subsequent call fails (have
to
| constantly test, while changing aspx))
|
|
| ---- ERROR ----------------------------
| An established connection was aborted by the software in your host machine
|
| Description: An unhandled exception occurred during the execution of the
| current web request. Please review the stack trace for more information
| about the error and where it originated in the code.
|
| Exception Details: System.Net.Sockets.SocketException: An established
| connection was aborted by the software in your host machine
|
|
|
| Thanks
| Nalaka
|
|
|

Nov 19 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.