ExceptionRoutedEventArgs.ErrorException 속성

정의

오류 조건을 발생시킨 예외를 가져옵니다.

public:
 property Exception ^ ErrorException { Exception ^ get(); };
public Exception ErrorException { get; }
member this.ErrorException : Exception
Public ReadOnly Property ErrorException As Exception

속성 값

Exception

특정 오류 조건을 설명하는 예외입니다.

예외

미디어 파일에 대한 액세스가 거부된 경우

미디어 파일이 없는 경우

미디어 파일 형식이 설치된 코덱에서 지원되지 않는 경우

또는

파일 형식을 인식할 수 없는 경우

Windows Media Player 버전 10 이상이 검색되지 않는 경우

또는

비디오 리소스가 미디어 재생에 부족한 경우

COM 오류 코드가 나타나는 경우

예제

다음 예제에 대 한 간단한 이벤트 처리기에서는 ExceptionRoutedEventArgs합니다.

private void Media_MediaFailed(object sender, ExceptionRoutedEventArgs args)
{
    MessageBox.Show(args.ErrorException.Message);
}
Private Sub Media_MediaFailed(ByVal sender As Object, ByVal args As ExceptionRoutedEventArgs)
    If (True) Then
        MessageBox.Show(args.ErrorException.Message)
    End If
End Sub

적용 대상