SPONSORS:






User Tag List

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

    Global and Local Sheet parameters

    I'm new to QTP and having a problem running my tests that uses both Global and Local sheets. For each iteration I want the rows for global and local sheets to match. For example, the first iteration will run row 1 of global and row 1 of ALL local sheets. The next iteration will be row 2 for all sheets and so on. The problem is the local sheets do not have data for all rows. So rows 1 and 2 would be blank but row 3 would have data in the local sheet. I want to do this so it ties back to Global Sheet.

    Thanks in advance

  2. #2
    Junior Member
    Join Date
    May 2004
    Location
    India
    Posts
    26
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Global and Local Sheet parameters

    If ive understood ur query,try this script in each action seperately...
    global = datatable(Colname,dtGlobalSheet)
    local = datatable(Colname,dtLocalSheet)
    If global = local
    perform some action
    Else
    perform some other action
    End if

    This should work ... since in successive iterations QTP is taking only the successive rows... eg for first iteration row 1 is taken and for iteration 2 second row is taken...
    regarding null data... try to catch it with seperate script
    Jacobs

  3. #3
    Junior Member
    Join Date
    Jul 2004
    Posts
    4
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Global and Local Sheet parameters

    Thanks Jacobs...that's not exactly what I was looking for.

    Can I force the local actions to use the same global row?

  4. #4
    Junior Member
    Join Date
    Jul 2004
    Posts
    4
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Global and Local Sheet parameters

    I think I found how to do it. Basically set the localsheet row to the global row.

    intRow = DataTable.GlobalSheet.GetCurrentRow
    DataTable.LocalSheet.SetCurrentRow(intRow)

  5. #5
    Member
    Join Date
    Jan 2004
    Location
    Mexico
    Posts
    95
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Global and Local Sheet parameters

    Yes, but you need configure in every script, your arguments most be in the global sheet.

    Then when make call in a Script compose, every script put thats argument in the global sheet of the sript compose. And all script that you call work with same global sheet.

    sorry for my english.

    saludos.
    fml

  6. #6
    Senior Member
    Join Date
    Jun 2003
    Location
    Tampa, FL
    Posts
    372
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Global and Local Sheet parameters

    quoc -- You should not have to do anything, the behavior you are describing is the default behavior for QTP. The global sheet controls the number of iterations for the testcase as a whole, but the individual action sheets EITHER walk in lockstep with it, or can loop independantly. Out of the box, they walk in lockstep with it. The fact that rows 1 and 2 have no data should not bother QTP, although what will your app do with an input statement that has no data?

    I am more curious as to why you are using the local sheet. The only two reasons to use the local sheet are 1) you want the action to use a different row, clearly not what you want, or 2) You are going to make the action reusable and shared, so it's data must me local to it, not global to the test; but if the two are linked together so tightly, I suspect that is not the case either. Is there any reason you dont just put everything in the global sheet? Much easier...

    Sincerely,
    David

  7. #7
    Junior Member
    Join Date
    Jul 2004
    Posts
    4
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Global and Local Sheet parameters

    Hi David,

    The default behavior does not work. I see the global and local row during execution and it doesn't match.

    I'm using local sheets because it's a resuable action and makes the parameters more manageable.

  8. #8
    Senior Member
    Join Date
    Jun 2003
    Location
    Tampa, FL
    Posts
    372
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Global and Local Sheet parameters

    quoc -- right click on the action, select action properties, and make sure "One Iteration Only" is selected. See if that helps.

    David

 

 

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 10.00%
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:14 AM.

Copyright BetaSoft Inc.