Questions tagged [svcutil.exe]

The ServiceModel Metadata Utility tool (SVCUTIL.EXE) is used to generate service model code from metadata documents and metadata documents from service model code.

Svcutil.exe can generate code for service contracts, clients and data types from metadata documents. These metadata documents can be on a durable storage, or be retrieved online. Online retrieval follows either the WS-Metadata Exchange protocol or the DISCO protocol

http://msdn.microsoft.com/en-us/library/aa347733.aspx

416 questions
7
votes
0 answers

Using svcutil.exe to generate identical namespace as Add Service Reference

I have a WCF service and when I add a reference to it using VS.NET 2012 via the Add Service Reference... option, I specify a namespace, in the bottom of the dialog (i.e. `MyNameSpace') This generates the following 1st few lines of code in the auto…
atconway
  • 20,624
  • 30
  • 159
  • 229
7
votes
2 answers

Errors/Warnings using svcutil.exe to create proxy classes for several WCF services

I'm writing a .NET 3.5 app and have control over both the WCF service and client. I'm using svcutil to generate proxy classes for my services, combining several services since they share data types. svcutil /out:ServiceReference.cs /noconfig…
Clyde
  • 8,017
  • 11
  • 56
  • 87
7
votes
3 answers

To test this service using svcutil.exe

I want to test a service with svcutil.exe. The step is svcutil.exe http://11.55.99.341/MessagingServices/MessageData.svc?wsdl I found that there is a cs file was generated in C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin. Some of code is…
user1108948
7
votes
2 answers

SVCUtil or WSDL batch processing

I was given a set of 170 WSDL files which I need to convert to C# class files. Is there any way to batch process this?
Hungry Beast
  • 3,677
  • 7
  • 49
  • 75
7
votes
2 answers

WSDL Generation for WCF Service Behind Load Balancer

The Background: I have a Service hosted on IIS 7.0 behind a Load Balancer which decrypts SSL as traffic passes through it. The security mode required of the Service is Mixed-Mode ie TransportWithMessageSecurity To enable the Service to accept HTTP…
JTech
  • 3,420
  • 7
  • 44
  • 51
7
votes
3 answers

svcutil.exe - Proxy generated not allowing for nullable fields

I am trying to consume a web service specified using WSDL by creating a WCF proxy using svcutil.exe, but the WSDL specifies that some of the operations have parameters that are optional (minOccurs="0"), for example:
David
  • 660
  • 7
  • 18
6
votes
3 answers

svcutil omits the ServiceKnownType attribute from the generated interface proxy

I encountered a problem when I tried to implement the ServiceKnownType example from MSDN. In the example they provide the following classes: [DataContract()] public class Widget { [DataMember] public string Id; [DataMember] public…
Andy
  • 1,153
  • 4
  • 13
  • 33
6
votes
2 answers

svcutil and specified fields

I am generating a datacontract with svcutil from a webservice. svcutil /language:cs /noConfig /targetclientversion:Version35 /out:Generated\ProductService.cs http://example.com/ProductService.svc?wsdl The fields generated looks like this: …
adrianm
  • 14,468
  • 5
  • 55
  • 102
6
votes
2 answers

svcutil.exe - How to get WSDL

I'm working with a SOAP interface. The interface provider is having trouble getting me the full WSDL (long story). They have asked me to use svcutil.exe to generate everything I need. From what I can tell, svcutil.exe requires windows - I don't…
three-cups
  • 4,375
  • 3
  • 31
  • 41
6
votes
1 answer

Can I force svcutil.exe to generate data contracts for a WCF service?

I would like to force svcutil to generate all data contracts in an assembly that is used by WCF, regardless of whether or not a type is referenced by a given operation contract. [DataContract] public class Foo { } [DataContract] public class Bar :…
Andrew Hare
  • 344,730
  • 71
  • 640
  • 635
6
votes
2 answers

How to get metadata using Svcutil.exe with an endpoint that has Tls 1.2

Does any one know how to make SvcUtil.exe connect to an end point that is using TLS 1.2? I am using .Net Framework version 4.6.1. When I connect using VS 2017 I can see using Fiddler the request is established over a tunnel using a ClientHello…
Tom Maher
  • 1,914
  • 2
  • 23
  • 39
6
votes
1 answer

SvcUtil and 'System.Xml.Linq.XElement' cannot be converted to 'System.Xml.XmlElement' compiler error

I always recieve the above error when I generate a proxy class for my service using SvcUtil. The service is exposing a property that is of System.Xml.Linq.XElement type. The SvcUtil generates a System.Xml.XmlElement type property unfortunately. On…
odehne
  • 61
  • 2
6
votes
1 answer

.Net SvcUtil: attributes must be optional

I'm trying to generate C# code classes with SvcUtil.exe instead of Xsd.exe. The latter is giving me some problems. Command line: SvcUtil.exe myschema.xsd /dconly /ser:XmlSerializer Several SvcUtil problems are described and solved…
Michel van Engelen
  • 2,791
  • 2
  • 29
  • 45
6
votes
1 answer

JavaToWs share types

I have a server in Java which has some web-services. WSDLs (and XSDs) are generated from java using javatows from apache cxf. Some services share types, and I would like to share these types also in wsdl is it possible? After that I want to…
Dusan Plavak
  • 4,457
  • 4
  • 24
  • 35
6
votes
1 answer

.NET SVCUTIL does not generate namespaces properly

I have a WSDL document with 2 namespaces, and I am trying to generate proxy classes using SVCUTIL.EXE. For some reason, in the generated code the types get placed into default namespace, not in the correct name for mapping provided. Here is my…
Greg Temkin
  • 76
  • 1
  • 3
1 2
3
27 28