willwatters Posted May 18, 2005 Share Posted May 18, 2005 When I use my script to select an option from a drop down menu in an application I'm testing, the contents of the drop down menu sometimes do no exsist to be selected, although I can do it manually E.g. send("!u") sleep(2000) send("s") Why does this happend and how do I resolve this problem please? Link to comment Share on other sites More sharing options...
herewasplato Posted May 18, 2005 Share Posted May 18, 2005 When I use my script to select an option from a drop down menu in an application I'm testing, the contents of the drop down menu sometimes do no exsist to be selected, although I can do it manuallyE.g.send("!u")sleep(2000)send("s")Why does this happend and how do I resolve this problem please?<{POST_SNAPBACK}>...with that sparse amount of script as an example, it is hard to tell what lines of code might be missing... I'm going to guess that you are not calling the window of interest into focus immediately before sending the Alt-u keys.E.g.WinWait("Some Window Title Goes Here","Text Here")WinActivate("Some Window Title Goes Here","Text Here")WinWaitActive("Some Window Title Goes Here","Text Here")Send("!u")Sleep(2000)Send("s")If the window of interest is not in focus, then your script (as written) will send the "Alt-u" and "s" keys to some other window or the desktop. You could also read up on the Control functions that work with some windows even if they do not have focus....of course, if I have not understood your problem correctly, then ignore my post :-) [size="1"][font="Arial"].[u].[/u][/font][/size] Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now