I have this test to see which control the contex menu pops up for but the problem is that it works for labels but not for Rich text boxes. In other words, when I right click on a text box no control is displayed in the messagebox but for labels it does.
private void contextMenu1_Popup(object sender, System.EventArgs e)
{
MessageBox.Show(""+this.contextMenu1.SourceControl);
}
Is that normal? I have in VSC# the Context menu section set to the same context menu for both.
private void contextMenu1_Popup(object sender, System.EventArgs e)
{
MessageBox.Show(""+this.contextMenu1.SourceControl);
}
Is that normal? I have in VSC# the Context menu section set to the same context menu for both.