开发者

Generate a WSDL from a dll?

开发者 https://www.devze.com 2023-03-30 17:56 出处:网络
Is it possible to generate a WSDL from a .NET ASMX-based web application without hosting it in IIS?Ideally, I\'d like to point svcutil.exe (or wsdl.exe?) to the dll and have it spit out all the WSDL f

Is it possible to generate a WSDL from a .NET ASMX-based web application without hosting it in IIS? Ideally, I'd like to point svcutil.exe (or wsdl.exe?) to the dll and have it spit out all the WSDL for the web application.

If you could provide the syntax for svcutil.exe that would be great. I've executed svcutil.exe /? and I can't seem to get the wsdl generation to happen (if it is at all possible).

If I call:

svcutil.exe myapplication.dll

I get the message:

Generating metadata files...
Warning: No metadata files were generated. No service contracts were exported.
To export a service, use the /serviceName option. To export data contracts, specify 
the /dataContractOnly option. This can sometimes occur in certain security contexts, 
such as when the assembly is loaded over a UNC network file share. If this is the 
case, try copying the assembly into a trusted env开发者_高级运维ironment and running it.

(Yes, I realize that ASMX is quite outdated. We are in the process of deprecating it.)

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号