Wait time?

Ranorex Spy, Recorder, and Studio.
jtoporowski
Posts: 7
Joined: Thu Apr 05, 2007 4:41 pm
Location: BC Canada

Wait time?

Post by jtoporowski » Thu Apr 05, 2007 4:51 pm

Is there a way to inject a wait time into a particular step? I guess this would have to be done on the code side and not using the recorder although that would be nice.

Our application loads data from a database into a dataset and the timing on this is not always exact. I recorded my actions and then played them back and the application was still loading when the recorder tried to input text into the login box. It only typed 3 of the 5 letters due to the load time.

Your thoughts?

Thanks,

Jesse

admin
Site Admin
Site Admin
Posts: 350
Joined: Wed Jul 05, 2006 7:44 pm

Post by admin » Sun Apr 08, 2007 5:05 pm

You have the following possibilities to change the replay speed at the moment:

1. You can use the Speed slider bar to set the general speed of the replay slower. The default speed is real time or 1.0. The range of speeds are from 0.1 through 10.0 times real time (0.1 makes the replay 10x slower).

2. You can save the data as an XML file and change the Time of each step with an XML editor.

Code: Select all

    <Record>
      <Message Id="513" Handle="0" Time="7357" ParamW="0" ParamL="0" Point="427,371" />
      <Form Title="Rechner" ClassName="SciCalc" Handle="1116002" Point="295,197" />
Open and replay the XML file with RanorexRecorder or start the replay action from the command line:

RanorexRecorder /play MyTest.xml

3. Generate C# sourcecode and embed it into your test application. You can easily change the wait time for each step this way.
The last parameter is the Time in most of the functions:

Code: Select all

    Mouse.ClickElement(element, MouseButtonType.LeftButton, new Point(19, 18), 1, 536);

This function moves the mouse to the element and clicks it, the time duration of this operation is 536 milliseconds.

I would suggest to generate C# code with the Recorder and then extend the code with some application specific checking functions.

Jenö
Ranorex Team