Answered by:
Make a window the active window

Question
-
How would i make so when i click a button it makes a window the active window, i mean a window of a program that is already running.
Any help would be greatly appreciatedFriday, January 16, 2009 8:09 PM
Answers
-
Microsoft.VisualBasic.Interaction.AppActivate("App Title or ProcessID")
- Proposed as answer by ronan001 Friday, January 16, 2009 11:43 PM
- Marked as answer by Michael Sun [MSFT]Microsoft employee Monday, January 19, 2009 10:32 AM
Friday, January 16, 2009 10:21 PM -
As John mentioned, you can call AppActivate from Microsoft.VisualBasic.dll,
Just be sure to add it to your References, If you try "Add Reference ..." you
will find it in ".NET" page tab in new window.
If your application is minimized, it will be activated but it doesn't come up (Restore).
http://www.floresense.com/resc_center/?art=1353
- Proposed as answer by Bin-ze Zhao Monday, January 19, 2009 8:41 AM
- Marked as answer by Michael Sun [MSFT]Microsoft employee Monday, January 19, 2009 10:32 AM
Friday, January 16, 2009 11:30 PM
All replies
-
Microsoft.VisualBasic.Interaction.AppActivate("App Title or ProcessID")
- Proposed as answer by ronan001 Friday, January 16, 2009 11:43 PM
- Marked as answer by Michael Sun [MSFT]Microsoft employee Monday, January 19, 2009 10:32 AM
Friday, January 16, 2009 10:21 PM -
As John mentioned, you can call AppActivate from Microsoft.VisualBasic.dll,
Just be sure to add it to your References, If you try "Add Reference ..." you
will find it in ".NET" page tab in new window.
If your application is minimized, it will be activated but it doesn't come up (Restore).
http://www.floresense.com/resc_center/?art=1353
- Proposed as answer by Bin-ze Zhao Monday, January 19, 2009 8:41 AM
- Marked as answer by Michael Sun [MSFT]Microsoft employee Monday, January 19, 2009 10:32 AM
Friday, January 16, 2009 11:30 PM