sada
sada

Reputation: 693

How can I use SimpleType in a WSDL data contract?

I use a wsdl file to generate web service with the help of svcutil but it generates class instead of simple int or string parameter for the service contract. What I did:

  1. I created a WCF Service Application
  2. I created a Console Application then added the service reference to the project
  3. I used svcutil.exeto generate service from thy wsdl and xsd files in console project

Why does it do that and how I can rewrite the wsdl to solve this problem, please?

Upvotes: 0

Views: 365

Answers (1)

Uriil
Uriil

Reputation: 12628

Most likely you used /messageContract switch in svcutil.

If you added service via service reference, then right click on service->configure service reference and uncheck Always generate message contracts

Upvotes: 1

Related Questions