Manipulate an external Windows application

  • Thread starter Thread starter John A. Bailo
  • Start date Start date
J

John A. Bailo

From a c# application I can launch an application with the Process class.

Once that app is launched, can I then manipulate it?

Example, say I launch notepad with:

p=new Process();
p.StartInfo.FileName = "notepad";
p.Start();

p.WaitForExit();

Can I simulate the effect of a mouse click and drag and move it around
the screen?
 
You will have to use winapi through pinvoke to first inspect the
application's UI and then send the appropriate messages through win32
api.

Regards,
Tasos
 
Back
Top