C# process.start runs multiple times instead of one

Apr 23 2013 4:17 AM
 
Hi,

I made an IE toolbar with addin Express and C# with buttons that run powershell scripts that interact with IE.
When I click on one of the buttons, my script is run 4 or 5 times. Some other buttons display the same behavior but more randomly.

I don't understand, the code is simple:


private void assign_Click(object sender, EventArgs e)
{

int h = IEApp.HWND;
Process.Start("powershell.exe", "-v 3 -STA -File " + scripts + "\\finalie.ps1 openoneinc " + h);

}


Any help appreciated.

Clovis