Share via


startEnvelope and endEnvelope Methods

Other versions of this page are also available for the following:

Windows Mobile Not SupportedWindows Embedded CE Supported

8/28/2008

These methods begin and end an <Envelope> element in a SOAP message.

Syntax

HRESULT startEnvelope( 
  BSTR env_Prefix, 
  BSTR enc_style_uri, 
  BSTR xml_encoding 
);
HRESULT endEnvelope (void);

Parameters

  • env_Prefix
    [in] Optional. Namespace for the SOAP elements. The default is "". If the parameter is an empty string or is missing, the application uses the value "SOAP-ENV".
  • enc_style_uri
    [in] Optional. Universal Resource Identifier (URI) for the encodingStyle attribute of the <Envelope> element. The following values have special meaning when assigned to this parameter:

    Value Description

    NONE

    Default. Use this value if you do not want encodingStyle attribute generated in <Envelope> element.

    STANDARD

    Use this value if you want to generate encodingStyle attribute with the default encoding style in the <Envelope> element.

  • xml_encoding
    [in] Optional. XML character encoding used for the SOAP message. The default is "". Uses "UTF-8" if this parameter is missing or is an empty string.

Return Value

The following table describes the common return values.

Value Description

S_OK

Success.

E_NOTIMPL

The function contains no implementation.

E_OUTOFMEMORY

Out of memory.

Remarks

Serializer.startEnvelope() is identical to Serializer.startEnvelope(NONE), which creates this <Envelope> element:

<Envelope>...</Envelope>

Serializer.startEnvelope("STANDARD") creates this <Envelope> element:

<Envelope encodingStyle="https://schemas.xmlsoap.org/soap/encoding/" >...</Envelope>

Serializer.startEnvelope("") creates this <Envelope> element:

<Envelope encodingStyle="">...</Envelope>

Serializer.startBody("SomeEncoding") creates this <Envelope> element:

<Envelope encodingStyle="SomeEncoding">...</Envelope>

Requirements

Header mssoap.h
Library uuid.lib
Windows Embedded CE Windows CE .NET 4.0 and later

See Also

Reference

ISoapSerializer