When the arrow-key-down button is pressed, this mapped object in my winform app will display a 'dropdown' panel,
Currently , it's neccessary that I use method .Keys('[Down]') on this object search_bar to stimulate the visibility/appearence of the 'dropdown' panel
self.search_bar .Keys('[Down]')
The panel does show up, however just for 1 second or so.
I need to make the 'dropdown' panel stayed for a longer time-frame, i.e. 50 seconds
How can I make the .Keys('[Down]') stay longer than 1 second as it would normally does.
self.search_bar = Aliases.SomeAppClient.Console.Streaming.Tabs.XyxStage.AbcSearchBar
Solved! Go to Solution.
Hi @HKTCentrix, since none of the suggestions helped, I am assuming your situation might require deeper investigation from our side.
Please contact the SmartBear Support Team and describe the issue you are facing in detail. Thank you!
I have tried using the timer
start_time = time.time()
while (time.time() - start_time < hold_time) :
self.search_bar.Keys('[Down]')
############################
Also, have tried this suggested somewhere in the forum:
self.search_bar.SetFocus()
self.search_bar.Keys('[Down]')
Sys.Desktop.KeyDown(Win32API.VK_CONTROL);
Delay(50000);
Sys.Desktop.KeyUp(Win32API.VK_CONTROL);
Nothing has worked!
You might look into https://support.smartbear.com/testcomplete/docs/reference/project-objects/items/llp/llplayer/index.h...
Do you need to have it HOLD the down key for a time?
If that's the case, there is a "HOLD" keyword in the "Keys" method that will allow you to hold a set of keys down until you release.
So, Keys('[Hold][Down]a[ReleaseLast]') will hold the down arrow and then tap the a key and then relase the down arrow.
Will this work for you?
LLPlayer Object does not work for me.
sDelay = 20000
self.search_bar.SetFocus()
self.search_bar.Keys('[Down]')
LLPlayer.KeyDown(VK_DOWN, sDelay); # (1)
self.search_bar.Keys('[Down]')
LLPlayer.KeyUp(VK_DOWN, sDelay); # (2)
Thrown in several lines of codes, with different orders of lines, and none of them make any difference.
All I got is " Waiting for a delay between low-level events" when line 1 and 2 got hit
No, this does not work for me either. The effect is the same as .Keys('[Down]')
self.stage_search.Keys('[Hold][Down][ReleaseLast]')
the letter a trick didn't work either.
self.stage_search.Keys('[Hold][Down]a[ReleaseLast]')
Hi @HKTCentrix, since none of the suggestions helped, I am assuming your situation might require deeper investigation from our side.
Please contact the SmartBear Support Team and describe the issue you are facing in detail. Thank you!
User | Count |
---|---|
2 | |
2 | |
2 | |
1 | |
1 |