Click to See Complete Forum and Search --> : Restricting inputs


ajbharani
March 12th, 2008, 11:51 PM
Hello friends,

I am trying to automate a windows application. During the execution, the user is not supposed to lose the focus of the window. So I am trying to restrict the keyboard and mouse inputs for a certain period. How can I achieve this?

Regards,
Bharani

MMH
March 13th, 2008, 12:11 AM
What do you exactly mean by "the user is not supposed to lose the focus of the window" ?
Do you want that window to stay on top? and yet you intend to use already opened form ?

well i dont understand your exact requirment.. but you can just try doing something like this...


1. frmWindow.Show(this);
2. frmWindow.ShowDialog(this);


I think this should work...

ajbharani
March 13th, 2008, 12:16 AM
Hi

I'm actually controlling an application through my program. The application which I control must stay on top and the user should not interrupt the action which is currently going on in the application.

Regards
Bharani