Re: wsdl
- From: "yurps" <yurps@xxxxxxxxxxx>
- Date: 4 Jul 2006 02:28:53 -0700
how can I use wdsl to generate a proxy like this?
Thanks
Jesse Houwing wrote:
Martin Honnen wrote:
yurps wrote:
I have a webservice which I must deploy then generate a proxy
stub and add to my website project and then compile that and
deploy. Thing is I have 3 environments DEV, UAT, and PRO and
I need to rename the class name and constuctor accordingly.
public class Molar :
System.Web.Services.Protocols.SoapHttpClientProtocol {
public Molar() {
this.Url = "http://mysite/MyWebService/Service.asmx";
}
but I need to change this to:
public class MolarDEV :
System.Web.Services.Protocols.SoapHttpClientProtocol {
public MolarDEV() {
this.Url = "http://mysite/MyWebService/Service.asmx";
}
Is there a wsdl switch I can use to do this automatically, as the fewer
manual steps
I have in my deployment the better.
Try wsdl.exe /? to find the command line options, as far as I can see
there is none for the class name but you can use/generate different
namespaces using e.g.
wsdl.exe /namespace:DEV
Why would you want to generate a proxy with the url integrated into it.
It's duplicating a lot of classes, for a configuration issue.
Why not use
Molar m = new Molar();
m.Url = "http://mysite.etc/Service.asmx";
If you want you can event put this url in the app/web.config file for
automatic configuration at runtime.
Jesse
.
- Follow-Ups:
- Re: wsdl
- From: Jesse Houwing
- Re: wsdl
- Prev by Date: Re: Enum Problems
- Next by Date: Re: Enum Problems
- Previous by thread: Re: Enum Problems
- Next by thread: Re: wsdl
- Index(es):
Relevant Pages
|