SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 6 of 6
  1. #1
    Junior Member
    Join Date
    Feb 2001
    Posts
    19
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Setting/Resetting Script Speed

    Sometimes when my script enters text it enters it so fast that it skips letters, etc.

    Does anyone have a VB Script example where at the beginning of the script I could set the speed to run slowly then at a certain point reset the speed to its normal running state?

    I'm out of ideas and not sure how to go about it. Thank you!

  2. #2
    Senior Member
    Join Date
    Apr 2006
    Location
    ked up until rehabilitated
    Posts
    515
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Setting/Resetting Script Speed

    You might consider using the .wText item rather than the Keys method. This will fill in the data internally, faster and more secure than the Keys method.

    Basically, the recorded Keys call would get slightly changed, as in the example below:

    w1.Window("Edit", "", 1).Keys("123456789[Tab]");

    to

    w1.Window("Edit", "", 1).wText = "123456789";

    notice that you will no longer need the Tab key to get through each of the fields.

    I hope this helps,
    Aaron Fager
    Software Test Engineer

    If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization.

  3. #3
    Apprentice
    Join Date
    Feb 2006
    Location
    Montreal
    Posts
    41
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Setting/Resetting Script Speed

    That's a weird thing! usually the script will input the string provided in the script. I don't know how it can skip a letter. Maybe there's some kind of process running in the background that kind of "lock" keyboard stroke. It can happen on web testing when the page loads images or some script executions occur while the page is loading. Maybe you could wait until you see the word "Done" on the browser's status bar at the bottom left of the window.

    Can't really think of anything else at this point.

    Good luck!
    Thanks,
    ~Dom

  4. #4
    Moderator
    Join Date
    Sep 2005
    Location
    Dublin, Ireland
    Posts
    1,878
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Setting/Resetting Script Speed

    GregV,

    While Aaron's answer is IMO the way to go for all data entry scripts, if you wish to remain with keyed entry, you can slow you script down by going into the 'Run' section of the 'Engine Options' and changing the 'Delay between events' to a larger value. 100ms should probably do the trick. This is not a great long term solution as you are unnecessarily slowing down your script execution. The Keys function is also prone to failing if you have different caps lock or num lock settings selected when you record and play back,

    Best regards,

    Shane

  5. #5
    Senior Member
    Join Date
    May 2004
    Posts
    1,196
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Setting/Resetting Script Speed

    Hi Greg,

    I guess you have TestComplete version 3. If this is the case, then we are aware of the issue you faced. It was solved in TestComplete 4.

    Unfortunately, there is no way to change the speed of typing in TestComplete 3. I recommend that you use the workaround suggested by Aaron.
    Best regards,
    David - SmartBear Support

  6. #6
    Junior Member
    Join Date
    Feb 2001
    Posts
    19
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Setting/Resetting Script Speed

    Thank you for all the replies! I haven't been able to get the "w.Text" to work yet but the "Engine Options" is doing the trick! Thanks to everyone for all the help!

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.36 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 9.38%
vBulletin Optimisation provided by vB Optimise v2.6.4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.2.8 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 06:48 PM.

Copyright BetaSoft Inc.