Forum Discussion
Since you are using object properties to click the field, it will not matter if the field moves. That's only an issue if you are using coordinates instead of the properties.
Timing issues may indeed come up but those are common and can be addressed with some version of Wait. If that happens to you, start another post and we can help you fix that.
The other downside of using Keys seems to be that I cannot pass a variable. I wanted to insert today's date in the field but it is going to be a lot more work to make it work with keys - if even possible! As of now, it is failing.
- Marsha_R4 years agoChampion Level 3
Keys will take a string
If your variable is not a string, you can convert it inline as you are passing it to Keys. There are examples here:
Here are other ways to convert from type to type:
https://support.smartbear.com/testcomplete/docs/reference/program-objects/aqconvert/index.html
- sonya_m4 years agoSmartBear Alumni (Retired)
- Logiv4 years agoContributor
Hello!
I did not have time to continue working on this.
The clicking in a problem for me because the whole grid is a single component. The object spy cannot focus on a single field, I get the whole grid.
So until I resolve that, it's going to be a little complex. The programmers won't change the code because I'm only QA, it's not a problem reported by a customer..
The field I was has it's own component, but it's only available once I have clicked in that field (and wait a few ms).I will try to find a way around this and test the suggestions but I won't have time this week.
Although, if I don't resize or move the window, my click works. I was able to enter my date in a string variable and that did not pass to keys, I had tried already. Maybe the links will show me something different than what I tried..