472,956 Members | 2,484 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,956 software developers and data experts.

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

May 24 '06 #1
6 2633
Right click on the project...
and select "Add Web Reference..."
and point to the WSDL

You are done!
--
Happy Hacking,
Gaurav Vaish
http://www.mastergaurav.org
http://www.edujini.in
-------------------
"Pierre" <bu****@no-log.org> wrote in message
news:11**********************@i39g2000cwa.googlegr oups.com...
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

May 25 '06 #2
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.

May 26 '06 #3
Hi Pierre,

You may want to try the following:

System.Diagnostics.ProcessStartInfo wsdlExeStartInfo = new System.Diagnostics.ProcessStartInfo(
"wsdl.exe", "/l:CS /edb /n:My.Company.Namespace /sharetypes
http://someserver/someservices.asmx");
System.Diagnostics.Process wsdlExe = System.Diagnostics.Process.Start(wsdlExeStartInfo) ;

You can of course wrap it in a method and parameterize the arguments passed
to wsdl.exe.
I believe you cannot redistribute wsdl.exe with your applications so you
will have to somehow locate it on the client machine and include .Net SDK
as a prerequisite for your application.

Does that help?

Best regards,
Robert Wilczynski.
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.

May 26 '06 #4
Here's an approach using
System.Web.Services.Description.ServiceDescription Importer:

http://blogs.msdn.com/kaevans/archiv...27/585013.aspx

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

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

"Pierre" <bu****@no-log.org> wrote in message
news:11*********************@38g2000cwa.googlegrou ps.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.


May 26 '06 #5
> "wsdl.exe", "/l:CS /edb /n:My.Company.Namespace
/sharetypes http://someserver/someservices.asmx");
System.Diagnostics.Process wsdlExe =
System.Diagnostics.Process.Start(wsdlExeStartInfo) ;


Would like to add just one modification, based on Piere's requirements.

0. Create a file services.txt with list of all asmx/services, one per line
1. Invoke the code above in a loop and replace the hard-coded location with
what you read from the file.
--
Happy Hacking,
Gaurav Vaish
http://www.mastergaurav.org
http://www.edujini.in
-------------------
May 27 '06 #6
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

May 30 '06 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: raymond | last post by:
Hi, Is it possible to create a proxy client class or a web service method by VS.NET without using wsdl? My stupid client is using a xml schema (.xsd) to describe all their web service methods...
5
by: Benne Smith | last post by:
Hi, I have three enviroments; a development, a testing and a production enviroment. I'm making a big application (.exe), which uses alot of different webservices. I don't use the webservices...
0
by: Daniel Thune, MCSE | last post by:
I am trying to use the WSDL.exe tool to create a proxy class for a webservice. I have the URL to the WSDL file for the service, but when I run the WSDL.exe tool and give it this URL I get the...
1
by: Savas Ates | last post by:
i was given an url bla bla.wsdl i am asked for entering data using this wsdl url? is it possible? how can i do it? must i use asp.net werb services .. any url or example or way t solve it...
1
by: Chenzo | last post by:
I have an issue where the provided .wsdl file is being generated incorrectly with the WSDL.exe tool. I have to use digital client certificates for authentication and it has been determined...by...
2
by: Anbu | last post by:
Hi, I have WSDL files generated by Java based Axis software. I need to use these WSDL files in ASP .NET. How can I import the WSDL files? Should i need to create a stub to using WSDL.exe to...
5
by: Pete Wittig | last post by:
Hi, Here is my problem. I have a serviced component that is exposed via a SOAP interface. This particular component, Person, has a method that takes in another object called PersonHobby. When...
4
by: Angel Of Death | last post by:
If server uses HTTP 1.1 Gzip compression, how can I use the classes generated using WSDL.exe. I can do : protected override WebRequest GetWebRequest(Uri uri) { WebRequest request =...
0
by: jeeshma | last post by:
hi, i am try to accessing a web page content(urls only) using wsdl in vs2005.for that i created a wsdl and proxy.ps help mel
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
2
by: giovanniandrean | last post by:
The energy model is structured as follows and uses excel sheets to give input data: 1-Utility.py contains all the functions needed to calculate the variables and other minor things (mentions...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
2
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.