ErrObject.GetException 메서드
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
발생한 오류를 나타내는 예외를 반환합니다.
public:
Exception ^ GetException();
public Exception? GetException ();
public Exception GetException ();
member this.GetException : unit -> Exception
Public Function GetException () As Exception
반환
발생한 오류를 나타내는 예외입니다.
예제
다음 코드는 예외에 할당 된 메시지를 표시 합니다 Err
개체:
On Error Resume Next
Dim myError As System.Exception
' Generate an overflow exception.
Err.Raise(6)
' Assigns the exception from the Err object to myError.
myError = Err.GetException()
' Displays the message associated with the exception.
MsgBox(myError.Message)
설명
GetException
함수를 에서만 사용할 수는 Err
개체 클래스입니다. 와 함께 작동 합니다 Exception
의 속성은 Err
발생 한 오류를 표시 하도록 개체입니다.