다음을 통해 공유


SmtpResponse.TryParse Method

The TryParse method gets a value that indicates whether the string specified by the text parameter contains a valid Simple Mail Transfer Protocol (SMTP) response.

Namespace: Microsoft.Exchange.Data.Transport.Smtp
Assembly: Microsoft.Exchange.Data.Transport (in microsoft.exchange.data.transport.dll)

Syntax

'Declaration
Public Shared Function TryParse ( _
    text As String, _
    <OutAttribute> ByRef response As SmtpResponse _
) As Boolean
public static bool TryParse (
    string text,
    out SmtpResponse response
)
public:
static bool TryParse (
    String^ text, 
    [OutAttribute] SmtpResponse% response
)
public static boolean TryParse (
    String text, 
    /** @attribute OutAttribute() */ /** @ref */ SmtpResponse response
)
JScript does not support passing value-type arguments by reference.

Parameters

  • text
    The string to validate.
  • response
    An instance of the SmtpResponse structure that represents the response that is contained in the text parameter. This parameter is passed uninitialized.

Return Value

The TryParse method returns true if the string specified by the text parameter contains a valid Simple Mail Transfer Protocol (SMTP) response; otherwise, the method returns false.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Platforms

Development Platforms

Windows XP Professional with Service Pack 2 (SP2), Windows Server 2003,

Target Platforms

Windows Server 2003