SoapBodyBinding.Encoding Property

Gets or sets a string containing a list of space-delimited URIs. The URIs represent the encoding style (or styles) to be used to encode messages within the SOAP body.

Namespace: System.Web.Services.Description
Assembly: System.Web.Services (in system.web.services.dll)

public:
property String^ Encoding {
	String^ get ();
	void set (String^ value);
}
/** @property */
public String get_Encoding ()

/** @property */
public void set_Encoding (String value)

public function get Encoding () : String

public function set Encoding (value : String)

Not applicable.

Property Value

A string containing a list of URIs. The default value is an empty string ("").

The value of this property should be set only if the value of the Use property is Encoded. Otherwise this property value will be ignored.

SoapBodyBinding^ mySoapBodyBinding = gcnew SoapBodyBinding;
// Encode SOAP body using rules specified by the 'Encoding' property.
mySoapBodyBinding->Use = SoapBindingUse::Encoded;
// Set URI representing the encoding style for encoding the body.
mySoapBodyBinding->Encoding = "http://schemas.xmlsoap.org/soap/encoding/";
// Set the Uri representing the location of the specification
// for encoding of content not defined by 'Encoding' property'.
mySoapBodyBinding->Namespace = "http://tempuri.org/soapsvcmgr/";
myInputBinding->Extensions->Add( mySoapBodyBinding );

SoapBodyBinding mySoapBodyBinding = new SoapBodyBinding();
// Encode SOAP body using rules specified by the 'Encoding' property.
mySoapBodyBinding.set_Use(SoapBindingUse.Encoded);
// Set URI representing the encoding style for encoding the body.
mySoapBodyBinding.
    set_Encoding("http://schemas.xmlsoap.org/soap/encoding/");
// Set the Uri representing the location of the specification 
// for encoding of content not defined by 'Encoding' property'.
mySoapBodyBinding.set_Namespace("http://tempuri.org/soapsvcmgr/");
myInputBinding.get_Extensions().Add(mySoapBodyBinding);

Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0, 1.1, 1.0

Community Additions

ADD
Show: