ExecutedRoutedEventArgs.Parameter 속성
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
명령의 데이터 매개 변수를 가져옵니다.
public:
property System::Object ^ Parameter { System::Object ^ get(); };
public object Parameter { get; }
member this.Parameter : obj
Public ReadOnly Property Parameter As Object
속성 값
명령별 데이터입니다. 기본값은 null입니다.
예제
다음 예제에서는 사용자 지정RoutedCommand에 대 한 ExecutedRoutedEventHandler 만듭니다. 처리기는 현재 시간 및 컨트롤의 SliderValue 속성을 통해 처리기에 ExecutedRoutedEventArgs.Parameter전달 되는 업데이트 TextBox 합니다.
// Executed Event Handler
//
// Updates the output TextBox with the current seconds
// and the target second, which is passed through Args.Parameter.
private void CustomCommandExecuted(object sender, ExecutedRoutedEventArgs e)
{
txtResults.Text = "Command Executed at " +
DateTime.Now.Second + " seconds after the minute \n\n" +
"The target second is set to " +
e.Parameter;
}
' Executed Event Handler
'
' Updates the output TextBox with the current seconds
' and the target second, which is passed through Args.Parameter.
Private Sub CustomCommandExecuted(ByVal sender As Object, ByVal e As ExecutedRoutedEventArgs)
txtResults.Text = "Command Executed at " & Date.Now.Second & " seconds after the minute " & vbLf & vbLf & "The target second is set to " & e.Parameter.ToString()
End Sub
설명
이 속성은 특정 명령에 의해 정의된 제네릭 데이터 매개 변수를 나타냅니다.
이 매개 변수가 필요하지 null 않은 경우 전달할 수 있습니다.
일반적으로 명령이 Parameter 실행될 때 특정 정보를 명령에 전달하는 데 사용됩니다. 데이터의 형식은 명령에 의해 정의됩니다.