Cyberactiva - webmaster tutorials, programming and videogames tricks

webmaster menu webmaster menu webmaster menu webmaster menu webmaster menu webmaster menu webmaster menu webmaster menu
  

using WSDL.exe programmatically

using WSDL.exe programmatically
Hi all,

I'm building a small app that allows users to create proxys by clicking
on an interface (web, winform).

I started my project, imported wsdl.exe (add reference) and tried to
figure out a way to use it programmatically (throught object browser,
research engines, msdn...).

But I have to admit it looks a bit opaque to me.

If anybody has some tips/knowledge on how to simply convert a command
line: wsdl.exe /l:CS /edb /n:My.Company.Namespace /sharetypes
http://someserver/someservices.asmx into an app with a user interface,
I'll be very happy to hear about it.

Looking forward to hear from you.

Best regards,

Pierre


Hi and thx for the answer Gaurav,

Unfortunatly I have around 20 WSs to link this way and some are
added/modified on a regular basis (quite a nightmare I admit).

The idea is to build a tool that builds 1 proxy for all these WSs using
1 namespace...(i'll pass all the advantages given by using wsdl.exe
against using the Add Web Reference).

If the user has to click on 1 button instead of asking me to do the
proxy I could save up some time to do more interesting things. I have
done a .bat, but the exe not being at the same path on every computers,
it's a rather limited approach.

Once more if anyone knows how to use WSDL.exe programmatically (or to
achieve the same in another way) I'd be gratful if this person could
share this knowledge.


Here's an approach using
System.Web.Services.Description.ServiceDescriptionImporter:

http://blogs.msdn.com/kaevans/archive/2006/04/27/585013.aspx

Kirk Allen Evans [msft]
blogs.msdn.com/kaevans

====Provided As-Is and Implies no Warranty====

"Pierre" wrote in message
news:1148637625.707931.68020@38g2000cwa.googlegroups.com...
> Hi and thx for the answer Gaurav,
>
> Unfortunatly I have around 20 WSs to link this way and some are
> added/modified on a regular basis (quite a nightmare I admit).
> The idea is to build a tool that builds 1 proxy for all these WSs using
> 1 namespace...(i'll pass all the advantages given by using wsdl.exe
> against using the Add Web Reference).
> If the user has to click on 1 button instead of asking me to do the
> proxy I could save up some time to do more interesting things. I have
> done a .bat, but the exe not being at the same path on every computers,
> it's a rather limited approach.
> Once more if anyone knows how to use WSDL.exe programmatically (or to
> achieve the same in another way) I'd be gratful if this person could
> share this knowledge.
>


Thank you for the fast and helpful answers guys,

Very nice article you've written there Kirk, that's what I needed.

Thank you again I appreciate the help.

Pierre


Register for freeMembers Area
Web MarketingLast Web Marketing
Web MarketingLast Programming Tips
Web MarketingLast News


Web Marketing Links and links exchange .