SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 4 of 4
  1. #1
    Junior Member
    Join Date
    Apr 2007
    Posts
    21
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Data Table, new test result writes over previous

    Hi,
    I need an advise –
    I’m running QTP script on the web page with 'For' loop, and the result of each loop (if something wrong appears) reflected in the Test Results Summary. But it’s not convenient and I decide to duplicate these test results in the Data table. I added the following:
    ……
    If(Environment("TestIteration")=1) Then

    'action

    End If
    …………
    DataTable.SetCurrentRow(Environment("TestIteration "))
    DataTable("Status",dtGlobalSheet)="PASS"
    DataTable.SetCurrentRow(Environment("TestIteration "))
    DataTable("Comments",dtGlobalSheet)=passComments

    The problem is, that only first row in my table is filled in. Each new test result writes over it. How can I captuer each new result on a new row?
    ???????????????

    Thanks

  2. #2
    Member
    Join Date
    Oct 2003
    Location
    Norfolk, VA
    Posts
    360
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Data Table, new test result writes over previo

    The global sheet is not the place to store test results as they will be deleted when the test ends. Try searching these forums for +excel +functions or look here:

    Donate a user defined function
    http://www.sqaforums.com/showflat.php?Number=347046

    I found several functions for excel that I've tweaked to my needs where I can post my results as I want.
    A good rule of thumb is to never measure with your thumb.

  3. #3
    Junior Member
    Join Date
    Apr 2007
    Posts
    21
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Data Table, new test result writes over previo

    Thanks for advice.
    But the major problem is ‘”How to capture each new result on a new row.””

  4. #4
    Moderator
    Join Date
    Jul 2005
    Location
    Delhi
    Posts
    15,575
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    7 Thread(s)
    Total Downloaded
    0

    Re: Data Table, new test result writes over previo

    Use this code

    rowcount = DataTable.GetSheet("Global").GetRowCount

    DataTable.GetSheet("Global").SetCurrentRow rowcount +1

 

 

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 11.54%
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 04:48 PM.

Copyright BetaSoft Inc.