Drop down menu in QTP

Hi,

I am new to QTP also to Automation testing. Our company requires us to validate if we can use QTP for testing and its urgent. I tried some use cases but there is one use case I am not able to do. I tried recording, coding but find hard luck. Below is my scenario

Login to any browser
you have a menu, clicking on it will open some more menus. These are hidden menus written in java script and I am not able to record them.

Can any of you help me resolve the problem?

TIA

-Bathi

Questions by Bathi

Showing Answers 1 - 9 of 9 Answers

The best advice I can give you is to find some articles/tutorials on Descriptive Programming (DP) in QTP. QTP's keyword view fails to identify many objects because their object properties change when they are run. In other words, the recorded object properties fail to map the object's run-time properties. This is what I can provide you with right now:

Set TestObject=Description.Create
TestObject("name").value="SomeValue"

You can call it this way:

Browser("Browser").Page("Page").WebList(TestObject).Select "Whatever"

  Was this answer useful?  Yes

Sycho

  • Dec 17th, 2007
 

Hi,

QTP does not capture Active Screen for WinMenu object but this object correctly populates in Local Action Object Repositry. However QTP records only one property of Menu object which objectmenutype. It is also not possible to Spy WinMenu object to see its Test Object Properties and Test Object methods.


Please correct me if i am wrong

CHEERS

CPS

  Was this answer useful?  Yes

wsulak

  • Mar 4th, 2009
 

I had the same issue, and I was able to resolve it by creating a virtual object on the menu item and then mapping it to the object in Object Repository.

It's easy to do.  Run the Virtual Object wizard, and then record your action, ie. click, double-click, etc on the menu item.   By the way, this is how you do it in QTP 9.0; I'm not sure about other versions.

Hope this helps.

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions