SoapMessage.Stage Property

Gets the SoapMessageStage of the SoapMessage.

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

public:
property SoapMessageStage Stage {
	SoapMessageStage get ();
}
/** @property */
public SoapMessageStage get_Stage ()

public function get Stage () : SoapMessageStage

Not applicable.

Property Value

The SoapMessageStage of the SoapMessage.

The Stage property can be accessed at any SoapMessageStage.

The following code example demonstrates how to determine the SoapMessageStage within the SoapExtension.ProcessMessage method.

public:
   virtual void ProcessMessage( SoapMessage^ message ) override
   {
      switch ( message->Stage )
      {
         case SoapMessageStage::BeforeSerialize:
            break;

         case SoapMessageStage::AfterSerialize:
            WriteOutput( message );
            break;

         case SoapMessageStage::BeforeDeserialize:
            WriteInput( message );
            break;

         case SoapMessageStage::AfterDeserialize:
            break;


      }
   }

public void ProcessMessage(SoapMessage message)
{
    switch (message.get_Stage()) {
        case SoapMessageStage.BeforeSerialize :
            break;

        case SoapMessageStage.AfterSerialize :
            WriteOutput(message);
            break;

        case SoapMessageStage.BeforeDeserialize :
            WriteInput(message);
            break;

        case SoapMessageStage.AfterDeserialize :
            break;

    }
} //ProcessMessage

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, 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

.NET Compact Framework

Supported in: 2.0, 1.0

Community Additions

ADD
Show: