SPONSORS:






User Tag List

Results 1 to 3 of 3
  1. #1
    Junior Member
    Join Date
    Dec 2002
    Location
    NOIDA,UP,INDIA
    Posts
    1
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    automate test cases related to context menu.

    "Hi. I am using SilkTest 5.5. I am not able to automate test cases related
    to context menu (which appears by right clicking), as neither I find any
    builtin class for that nor I was able to write my own class/methods for
    that. Can anybody please provide me any help on how to use Context menus in
    SilkTest. Thanks in advance for any help/guidance."

  2. #2
    Senior Member
    Join Date
    Feb 2000
    Posts
    1,497
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: automate test cases related to context menu.

    Take a look at PopupMenu.

    John




    ------------------

  3. #3
    Junior Member
    Join Date
    Jan 2002
    Location
    Sacramento,CA
    Posts
    7
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: automate test cases related to context menu.

    Menu Items in popups are difficult only because you really can't record them and expect them to play back once objects move (PopupSelect requires xPos, yPos, sMenuItem as args)..., but they can be relatively easy to script. For example, if you have a listview (such as the Fonts window in the control panel), and you want Properties for Arial, you may get something like:
    Fonts.FontList.PopupSelect(33,21,"Properties"). If you change the view to List or Small Icons, 33,21 may be Courier or some other font that occupies that position.

    Create a new method to handle the moving object, and you should be set:
    winclass ListView: ListView// extend ListView
    void MyPopupSelect(ANYTYPE aItem, STRING sMenuItem)
    RECT r = this.GetItemRect(aItem)
    //gets position and size of item
    INT x = r.xPos
    INT y = r.yPos
    this.PopupSelect (x, y, sMenuItem)

    If it can walk on water, it's probably SilkTest.

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin 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 12:53 PM.

Copyright BetaSoft Inc.