Glossary Item Box
This walkthrough is made up of the following activity:
To write the code in Visual Basic
To write the code in C#
The following example shows what the code for the method looks like.
' Visual Basic
Private Sub tlbARToolbox_ButtonClick(ByVal sender As System.Object, ByVal e As _ System.Windows.Forms.ToolBarButtonClickEventArgs) Handles tlbARToolbox.ButtonClick
If (e.Button.Tag.ToString() <> "Pointer") Then
Designer1.ToolBoxItem = e.Button.Tag.ToString()
Else
Designer1.ToolBoxItem = Nothing
End If
End Sub
//C#
private void tlbARToolbox_ButtonClick(object sender, System.Windows.Forms.
ToolBarButtonClickEventArgs e)
{
if(e.Button.Tag.ToString() != "Pointer")
{
designer1.ToolBoxItem = e.Button.Tag.ToString();
}
else
{
designer1.ToolBoxItem = null;
}
}
See Also |
Copyright © 2004-2005 Data Dynamics, Ltd. All rights reserved.