Hello
I am making a Plug-In, a new popup menu, now.
I was able to indicate my menu form based on the samples.
(I thank the people who made a sample greatly.)
But I'm in trouble about 2 problems at present.
Can't I have advice?
1.Form isn't sometimes shown to a front from the 2nd time.
And previous Form doesn't sometimes disappear.
2.The short cut commands aren't normally carried out.
SendKeys.Send("^A"); //NG
'OpenFileDialog' appear !
program
//----------------
//Show My popup menu
protected override void Execute()
{
Form1 f = new Form1();
//get mouce position
int x = System.Windows.Forms.Cursor.Position.X; //X
int y = System.Windows.Forms.Cursor.Position.Y; //Y
f.StartPosition = FormStartPosition.Manual;
f.Visible = true;
f.Activate();
}
//----------------------
//Execute command
private void button2_Click(object sender, EventArgs e)
{
this.Visible = false;
SendKeys.Send("^A"); //NG
}
private void button3_Click(object sender, EventArgs e)
{
this.Visible = false;
SendKeys.Send("^{ENTER}"); //OK
}
private void button4_Click(object sender, EventArgs e)
{
this.Visible = false;
SendKeys.Send("^{UP}"); //OK
}
private void button5_Click(object sender, EventArgs e)
{
this.Visible = false;
SendKeys.Send("^{DOWN}"); //OK
}