DataGrid.ShowParentDetailsButtonClick 事件
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
發生於按一下 ShowParentDetails
按鈕時。
public:
event EventHandler ^ ShowParentDetailsButtonClick;
public event EventHandler ShowParentDetailsButtonClick;
member this.ShowParentDetailsButtonClick : EventHandler
Public Custom Event ShowParentDetailsButtonClick As EventHandler
事件類型
範例
下列程式碼範例示範如何使用這個成員。
private:
void CallShowParentDetailsButtonClick()
{
myDataGrid->ShowParentDetailsButtonClick += gcnew EventHandler( this, &MyForm::DataGridShowParentDetailsButtonClick_Clicked );
}
// raise the event when ParentDetailsButton is clicked.
void DataGridShowParentDetailsButtonClick_Clicked( Object^ /*sender*/, EventArgs^ /*e*/ )
{
String^ myMessage = "ShowParentDetailsButtonClick event raised";
// Show the message when event is raised.
MessageBox::Show( myMessage, "ShowParentDetailsButtonClick information" );
}
private void CallShowParentDetailsButtonClick()
{
myDataGrid.ShowParentDetailsButtonClick +=
new EventHandler(DataGridShowParentDetailsButtonClick_Clicked);
}
// raise the event when ParentDetailsButton is clicked.
private void DataGridShowParentDetailsButtonClick_Clicked(object sender, EventArgs e)
{
string myMessage = "ShowParentDetailsButtonClick event raised";
// Show the message when event is raised.
MessageBox.Show(myMessage, "ShowParentDetailsButtonClick information");
}
Private Sub CallShowParentDetailsButtonClick()
AddHandler myDataGrid.ShowParentDetailsButtonClick, AddressOf _
DataGridShowParentDetailsButtonClick_Clicked
End Sub
' raise the event when ParentDetailsButton is clicked.
Private Sub DataGridShowParentDetailsButtonClick_Clicked(ByVal sender As Object, ByVal e As EventArgs)
Dim myMessage As String = "ShowParentDetailsButtonClick event raised"
' Show the message when event is raised.
MessageBox.Show(myMessage, "ShowParentDetailsButtonClick information")
End Sub