Gets the text describing the error.
[Visual Basic]
<Serializable>
Overrides Public ReadOnly Property Message As String
[C#]
[Serializable]
public override string Message {get;}
[C++]
[Serializable]
public: __property virtual String* get_Message();
[JScript]
public
Serializable
function get Message() : String;
The text describing the error.
This is a wrapper for the DB2Error.Message property of the first DB2Error in the Errors property.
[Visual Basic, C#] The following example displays the DB2Error.Message of the first DB2Error within a DB2ErrorCollection collection.
[Visual Basic]
Public Sub DisplayDB2ErrorCollection(myException As DB2Exception)
MessageBox.Show("Message: " + myException.Message + ControlChars.Cr _
+ "StackTrace: " + myException.StackTrace + ControlChars.Cr
End Sub
End Class
[C#]
public void DisplayDB2ErrorCollection(DB2Exception myException)
{
MessageBox.Show("Message: " + myException.Message + "\n" +
"StackTrace: " + myException.StackTrace + "\n";
}