Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how to recognize menu options in dp in qtp
#11
Solved: 11 Years, 4 Months ago
Let us wait for Ankur's comment and see If he has any other option.
Reply
#12
Solved: 11 Years, 4 Months ago
In tools > options >windows aplications > advanced >record settings option> Menu

Select "Ignore menu initialization" record the menu part and let me know the result.
Want to fast track your QTP/UFT Learning? Join our UFT Training Course
Reply
#13
Solved: 11 Years, 4 Months ago
Hi Ankur,

I tired as u said, but didnt see any change,
script is recording as usual Window("Flight Reservation").WinMenu("Menu").Select "File;Open Order..."
and i did object spy on file;New orders and file;Open Orders, obects are geting identified as Window::Window

I didnot see any change.
I think it is not at all possible to use descriptive programming for WinMenu("Menu").

Let us know your comment.......
Reply
#14
Solved: 11 Years, 4 Months ago
Guys,

After analyzed i got solution for this so please try this code in QTP 9.2 for Window menu option

Code:
dim A,B
set A=description.create()
set B=description.create()
A("text").value="Flight Reservation"
B("menuobjtype").value=2
window(A).Activate
window(A).winmenu(B).select "File;Open Order..."


Please correct me if I'm wrong.
Reply
#15
Solved: 11 Years, 4 Months ago
it's great dude,

it's working fine but i am not able to understand "B("menuobjtype").value=2"
is this a property of the object, what does that 2 stands for.
if possible could you pls explain this.
Reply
#16
Solved: 11 Years, 4 Months ago
I write this script based on the OR. In OR, for Winmenu description properties shown as "menuobjtype value=2".

Sorry Rajesh, I dont know exactly what "2" indicates. Because we implemented tool this month and we are in knowledge base.

If any body know please explain its useful for all.
Reply
#17
Solved: 11 Years, 4 Months ago
hi ,
back on the forum after a vacation
The WinMenu(windows menu) test object does not have any test object properties.

The number 2 is called the index number of the item in the menu.

the index starts from 1 and continues.I.e
if you want to select the first item the index will be 1
if you want to select the second item the index will be 2
and it goes on

and the question is not clear you can use it like this
Code:
Browser("Customize Your Settings_2").WinMenu("ContextMenu").Select "<Item [b]2[/b]>"
Reply
#18
Solved: 11 Years, 4 Months ago
Thanks Hari.. Smile You mean that index 1 for New and Index 2 for open
is it ?
Reply
#19
Solved: 11 Years, 4 Months ago
yes ,

the above mentioned code is for WINDOWS browser

if it is to be used for the flight application then it can be used as

Window("Flight Reservation").WinMenu("Menu").Select "<Item 1>;<Item 2>" (TO SELECT FILE AND THEN OPEN)


in case of any thing else reply back
Reply
#20
Solved: 11 Years, 4 Months ago
it's cool.......

Thanks man.....
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Unable to recognize objects in SilverLight application through QTP Guest877 1 2,653 08-03-2018, 08:33 AM
Last Post: Manisha
  When trying to recognize the object in QTP, each object is recognized as “WinObject:S geetasarvadnya 2 3,765 10-28-2015, 12:34 PM
Last Post: vinod123
  QTP does recognize object chadadus 7 4,556 09-05-2014, 01:16 AM
Last Post: chadadus
  QTP 11 and IE9 64bit on Win7&SP1 64bit, QTP does not recognize objects in website jpalos 4 8,710 08-27-2014, 10:11 AM
Last Post: vinod123
  Handling .NET framework menu in webpage using QTP 10 vishnu1067 0 2,333 05-15-2014, 05:30 PM
Last Post: vishnu1067

Forum Jump:


Users browsing this thread: 2 Guest(s)