简体   繁体   中英

How to dynamically generate WSDL file and invoke the service?

I'm looking for an example in C# how to programmatically create WSDL file based on XSD files where WSDL file contains 1 main XSD file, which contains several import directives to subsequent XSD files. After that WCF service should be invoked based on created WSDL file. The service contract is known.

I've spent a lot of time on internet trying to find something but no luck so far.

There is a program that comes with .net sdk called wsdl.exe You could invoke this program using the methods of the Process class.

See this:

http://msdn.microsoft.com/es-es/library/e8zac0ca.aspx

And this:

http://msdn.microsoft.com/en-us/library/7h3ystb6(v=vs.100).aspx

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM