|
Menu handler is 0 for Explorer folder main menu
|
|
09-10-2009, 11:02 AM
I guess it wont work until unless you click on the Menu of which submenu you want to get the handle.
Try to click the menu and then get the submenu handle. let me know if it works.
09-10-2009, 02:16 PM
Thank you a lot for the idea, but it looks like it is not the cause of the problem:
1. If I run this part of code WordPad it retrieves all handlers successfully ' Get the Handle of the main window. Make sure you launch wordpad.exe before you run this example (insted of folder window) WinHandle = Window("title:=.* - WordPad", "index:=0").GetROProperty("hwnd") 2. I click on File menu (and still the problem is the same) Window("regexpwndtitle:="&strWin).WinToolbar("regexpwndclass:=ToolbarWindow32","windowstyle:=1442895949").Press "&File" My guess here is that the problem is because of objects hierarhy (our menu context is on the menu bar) and it seems that MenuHandle = Extern.GetMenu(WinHandle) is not the handler to the main menu. When I try to spy the menu the handler is not the same I get from the script ![]() What do you think about this? Will be really appreciate any thoughts.
09-10-2009, 05:58 PM
Yes you are right Andriana, these menus are implemted as toolbarwin32 class. As this is not a standard menu, it can not be handled using GetMenu API. may be using WM_INITMENU will help. I will just check and get back.
|
|
« Next Oldest | Next Newest »
|
| Possibly Related Threads… | |||||
| Thread | Author | Replies | Views | Last Post | |
| Unable to perform click operation on MDI menu/sub menu (Infragistics) with UFT 12 | Mahen1108 | 0 | 3,807 |
06-17-2015, 05:29 PM Last Post: Mahen1108 |
|
| Problem with menu object (UFT) | Marta79 | 4 | 4,888 |
05-07-2015, 12:44 PM Last Post: Marta79 |
|
| QTP 11 is not working for Internet Explorer 10 | Niraj | 5 | 11,021 |
08-14-2013, 01:34 PM Last Post: Niraj |
|
| Explorer Crash - when UFT 11.5 is open | sriramb | 2 | 4,246 |
07-08-2013, 05:18 PM Last Post: Ankur |
|
| create drop Down list or menu in qtp | abansal | 0 | 4,400 |
09-07-2012, 05:36 PM Last Post: abansal |
|
Users browsing this thread: 1 Guest(s)


