In my sample code, Service1() was the name I chose for the class that
represents the proxy that is generated for the web service. Since I don't
know the name of your web service class, I just took the default. You need
to translate...
I'm not sure I understand your question about a windows application. Isnt'
the windows application calling the web service? Or do you mean you have
an ASP.net web applicaiton that has server side logic that is invoked by a
web-form, and in that logic, you try to call the web service? If this is
the case (the latter, not the former), then you need to supply specific
credentials, since the current credentials won't work for the server side
application (it has a very low-permission identity).
I hope this helps
Dan
--------------------
Thread-Topic: WebService
thread-index: AcTd4x9rPeDHKLX ATmOyvfaT7HBSww ==
X-WBNR-Posting-Host: 213.41.107.71
From: "=?Utf-8?B?TWFjTGFuY2E =?=" <Ma******@discu ssions.microsof t.com>
References: <BB************ *************** *******@microso ft.com>
<Ha************ **@cpmsftngxa10 .phx.gbl>
Subject: RE: WebService
Date: Thu, 9 Dec 2004 03:35:02 -0800
Lines: 78
Message-ID: <EB************ *************** *******@microso ft.com>
MIME-Version: 1.0
Content-Type: text/plain;
charset="Utf-8"
Content-Transfer-Encoding: 8bit
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.publi c.dotnet.framew ork.webservices
NNTP-Posting-Host: TK2MSFTNGXA03.p hx.gbl 10.40.1.29
Path: cpmsftngxa10.ph x.gbl!TK2MSFTNG XA03.phx.gbl
Xref: cpmsftngxa10.ph x.gbl
microsoft.publi c.dotnet.framew ork.webservices :7995
X-Tomcat-NG: microsoft.publi c.dotnet.framew ork.webservices
Dan,
Thank you for your help, but I've got a few more questions.
Wath's the service1(), webservice itself ?
And why thoes the windows application works(it's behind the firewall to)?
"Dan Rogers" wrote:
When you say ISA server, do you mean an HTTP proxy server between your
caller and the service? if so, you need to configure the proxy settings
in your calling program with something like the following:
Service1 svcProxy = new Service1();
// Configure to use an HTTP proxy server for clients behind the firewall
//
System.Net.WebP roxy prx = new System.Net.WebP roxy("myISAServ erName");
// Set to use the current logged in interactive users credentials (works
for winforms interactive apps)
prx.Credentials = System.Net.Cred entialCache.Def aultCredentials ;
// Assign the HTTP proxy to the SOAP service proxy
svcProxy.Proxy = prx;
When you have a caller behind a firewall and a service on the internet,
you have to have logic in the client accomplish these steps. Different forms
of the System.Net.Cred ential can be done to work around non-interactive
users (such as web service behind the firewall calling a service on the
internet).
Hope this helps
Dan Rogers
Microsoft Corporation
--------------------
Thread-Topic: WebService
thread-index: AcTca1nTBxVV6HL dSnGM4MfxLjqirw ==
X-WBNR-Posting-Host: 213.41.107.71
From: "=?Utf-8?B?TWFjTGFuY2E =?=" <Ma******@discu ssions.microsof t.com>
Subject: WebService
Date: Tue, 7 Dec 2004 06:45:10 -0800
Lines: 10
Message-ID: <BB************ *************** *******@microso ft.com>
MIME-Version: 1.0
Content-Type: text/plain;
charset="Utf-8"
Content-Transfer-Encoding: 8bit
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.publi c.dotnet.framew ork.aspnet.webs ervices,microso ft.public.dotne t .framework.webs ervices
NNTP-Posting-Host: TK2MSFTNGXA03.p hx.gbl 10.40.1.29
Path:
cpmsftngxa10.ph x.gbl!TK2MSFTFE ED02.phx.gbl!TK 2MSFTNGXA01.phx .gbl!TK2MSFTNGX A 03.phx.gbl
Xref: cpmsftngxa10.ph x.gbl
microsoft.publi c.dotnet.framew ork.webservices :7946
microsoft.publi c.dotnet.framew ork.aspnet.webs ervices:27070
X-Tomcat-NG: microsoft.publi c.dotnet.framew ork.webservices
Hi,
I've done the HelloWorld WebService, installed in a WebServer (INTERNET)
When I call it with Windows App it works, if I use a webform it
doesn’t (INTERNET)
Both of them work in the INTRANET
The code I use is the same, and I have an ISA server.
Can anyone help me please?
Error:"The underlying connection was closed: Unable to connect to the
remote
server"