C
chovatia.jaydeep
Hi,
I want to fetch Excel Command Bar and Status bar handles. To get
handles, i have written following code:
Please assume that excel application is already opened on desktop
whose caption is "EXCEL_TEST".
------------------------------------------------------------------------------------------------------------------------------------------------
Line1: HWND hWndMainXLS = FindWindow("XLMAIN",
"EXCEL_TEST");
Line2: HWND hWndStatusBar = FindWindowEx(hWndXLDesk, 0,
"EXCEL4", NULL);
Line3: HWND hWndCommandBar = FindWindowEx(hWndXL, 0,
"MsoCommandBar", NULL);
------------------------------------------------------------------------------------------------------------------------------------------------
In above code, Line 1 and Line 2 successfully returns handler of main
excel sheet and status bar, but code in Line3 returns NULL handler. In
nutshell, above code doesn't return me the correct handler for
CommandBar.
Please let us know what is the problem in the code.
Thank You,
Jaydeep
I want to fetch Excel Command Bar and Status bar handles. To get
handles, i have written following code:
Please assume that excel application is already opened on desktop
whose caption is "EXCEL_TEST".
------------------------------------------------------------------------------------------------------------------------------------------------
Line1: HWND hWndMainXLS = FindWindow("XLMAIN",
"EXCEL_TEST");
Line2: HWND hWndStatusBar = FindWindowEx(hWndXLDesk, 0,
"EXCEL4", NULL);
Line3: HWND hWndCommandBar = FindWindowEx(hWndXL, 0,
"MsoCommandBar", NULL);
------------------------------------------------------------------------------------------------------------------------------------------------
In above code, Line 1 and Line 2 successfully returns handler of main
excel sheet and status bar, but code in Line3 returns NULL handler. In
nutshell, above code doesn't return me the correct handler for
CommandBar.
Please let us know what is the problem in the code.
Thank You,
Jaydeep