Forum Discussion
I alreday added aDelay in the script before the YES and after the YES button is clicked
Try this... put a breakpoint on the Set Variable value.... run the test to the breakpoint... then step over... while still in debug, do a "watch" to look at the value of the variable... did it get set?
This is all debugging, all working with the code, all trying to see what the behavior is and determining, once you have observed the behavior, what is necessary to correct it. GENERALLY speaking, the code is correct... you click the button, you assign the value, then you try to consume it. So, we need to figure out WHY the set variable value is not actually getting a value.
So...
1) Are you getting errors?
2) What is the ACTUAL observed behavior when the test runs?
You're asking me to diagnose static code via screenshots when the problem is most likely an issue during runtime. I can only suggest. You'll need to do the work. Perhaps the delay you put in wasn't long enough. Again... you need to OBSERVE the behavior... you click the "Yes" button... is there a time period between clicking the button and when the work order number field is populated (a question I asked and you didn't answer)? THAT, right there, could be the ENTIRE problem... but we don't know that yet. Take the time, do the work, diagnose what's going on.
- saranoor6 years agoFrequent Contributor
So the stored value is not being used in the next step, the test is running and selecting the first row of workorder number which is not correct. The script needs to select the workorder number from UI that is in stored variable.