Hello,
I have created a code to open up an external program by using the Shell command, and I now need to enter a password to gain access to the application.
How can I:
1. Select the password field
2. Enter the required text
3. Continue navigating the program's interface
Thank you for your help.
Hello,
The easiest way would probably be to use Sendkeys
i.e.
Shell ("C:\WINDOWS\system32\notepad.exe"), vbMaximizedFocus
'opens external program and latches on
Application.Wait (Now + TimeValue("0:00:03"))
'Delays next action while application starts-up
SendKeys "hello", True
'Enters hello in whichever textbox, dropdown menu etc is active when external program is launched
If program is launched and the specific texbox is not active you can use
SendKeys "{ENTER}" or "{SHIFT}" etc to navigate around the application
Here is a list of keys: http://orlando.mvps.org/SendKeysMore.asp
Hope this helps![]()
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks