SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 6 of 6
  1. #1
    Member
    Join Date
    Dec 2002
    Location
    Colorado
    Posts
    61
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    java radio button

    I've tried to research this, but haven't had luck. Mercury support directed me to KB article #21850 which I did not see how it was applicable.

    I need to get QTP to choose the right option from the dropdown then click the radio button. The only thing that is unique about each of these is the label. Help!

    I sent the following off to Mercury:

    Description
    Windows 2000
    Java Console states: Loading Mercury Interactive QuickTest
    Professional Java Support (version 8.2.1149.0) (SUN 1.5.0_06)

    I am evaluating QTP for testing a java application. I am first recording the simple task of clicking on a dropdown menu and clicking a radio button from that menu. And to do this four times to check all the options on the dropdown menu. On playback it will find the first one, but none of the rest. I receive an error that it cannot find the parent properties of the object. It acts like it can move to the right place in the menu, but not click the radio button. I
    have been trying to find unique properties for each menu item, but it still doesn't want to click the radio button to choose that item.
    Below is the four lines pertaining to this issue. Please help me to find a work around or code to work with this.

    JavaWindow("TCAdvisor II - Accounts").JavaMenu("Accounts").JavaMenu
    ("Position and Holdings").Select
    JavaWindow("TCAdvisor II - Accounts").JavaMenu("Accounts").JavaMenu
    ("Tax Information").Select
    JavaWindow("TCAdvisor II - Accounts").JavaMenu("Accounts").JavaMenu
    ("Assets in Transfer").Select
    JavaWindow("TCAdvisor II - Accounts").JavaMenu("Accounts").JavaMenu
    ("Registration").Select

  2. #2
    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: java radio button

    Can you send your script to me on my id tarun_lalwani_2000(at)yahoo(dot)com (and send the whole script in zipped format). I think there is one thing lacking in this forum that is the ability to attache a file with your post. I had seen some forums earlier which have that capability. Hope the forum admin will take this as a suggestion and implement it in a future QA Forum.

  3. #3
    Super Member
    Join Date
    Oct 2004
    Posts
    1,222
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: java radio button

    dleslick, try using the index property. If there are 4 radio buttons under the parent, these should be numbered 0-3. Instead of logical names like "Registration", try using descriptive programming as such "index:=0". Throw in more than just the index property for identification for good measure. Hope that helps.

    Tarun, I am not sure allowing people to attach their script files is such a great idea. It places the onus of ensuring that no protected/confidential material is passed on the owners of betasoft.
    (I'm hiring Software Development Engineers in Test in Seattle, WA)

  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: java radio button

    Originally posted by Mark M:
    Tarun, I am not sure allowing people to attach their script files is such a great idea. It places the onus of ensuring that no protected/confidential material is passed on the owners of betasoft.
    <font size="2" face="Verdana, Arial, Helvetica">Well too certain extent it's very true...but i see that some people are not able to describe their problem in a manner which helps some one else to solve there issue. i remember one post where in i had exchanged 6-7 mails with the person
    having the problem. I was able to solve and it was very simple one,but the way the problem was described made it difficult to solve it in the first shot, so i think it does help a lot. And i believe ppl need to take care that they don't attach anything that creates copyright issues...

    With great powers comes great responsibilities [img]images/icons/wink.gif[/img]

  5. #5
    Super Member
    Join Date
    Oct 2004
    Posts
    1,222
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: java radio button

    Thats true Tarun. Unfortunately, not everyone understands that. In the past I have seen people paste their scripts as is...with company names, department names, employee names, etc. Lord help us if a tester for a credit card company were to do that. Or maybe not [img]images/icons/wink.gif[/img]
    (I'm hiring Software Development Engineers in Test in Seattle, WA)

  6. #6
    Member
    Join Date
    Dec 2002
    Location
    Colorado
    Posts
    61
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: java radio button

    Tarun - thank you very much for your help. I hope that Mercury is paying you some cash on the side for how much help you provide!

    Just an update to my issue:

    I did a webex with a systems engineer from Mercury and she found two things to help my woe with this Java menu.

    First, when I did the original recording of the menu, the objects didn't get named correctly in the repository. So consequently, on play back, they were not found. A little editing and tada, it played back fine.

    Second, she also used the index to move from one menu item to another. This is funny because the index of my menu is not ordered as expected! But with some trial and error, I know which one is which. The following actually chooses the third item in my menu:

    JavaWindow("TCAdvisor II - Accounts").JavaMenu("Accounts").JavaMenu(0).Select

    So hopefully this info will help some others out there.

    Good luck!

 

 

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 06:27 AM.

Copyright BetaSoft Inc.