aron bock
2005-06-20 06:10:57 UTC
Hello,
Using C#, WinXP, I'm trying to programmatically click a toolbar button (if
that's what it's called) in a ToolbarWindow32 control. Specifically, in
Internet Explorer 6, I want to issue a SendMessage call that would click
File/Open.
I've been able to do this with plain menu items as in Notepad. For this I:
--get the applications menu, using GetMenu
--get the File menuitem, using GetSubMenu
--get the "Open" menuitem's ID, using GetMenuItemID
--issue SendMessage to the app, using the menu item ID from above
Thus far, here's what I have with ToolbarButton32:
--get IE's hWnd
--find the ToolbarWindow32 of interest, using EnumChildWindows
--get the "File" toolbutton, using SendMessage with TB_GETBUTTON; this gives
me its "command ID"
Now I don't see a function/message to get the "Open" toolbutton, which is a
sub-button of File.
Would somebody point out what I should be doing?
Thanx
--A
Using C#, WinXP, I'm trying to programmatically click a toolbar button (if
that's what it's called) in a ToolbarWindow32 control. Specifically, in
Internet Explorer 6, I want to issue a SendMessage call that would click
File/Open.
I've been able to do this with plain menu items as in Notepad. For this I:
--get the applications menu, using GetMenu
--get the File menuitem, using GetSubMenu
--get the "Open" menuitem's ID, using GetMenuItemID
--issue SendMessage to the app, using the menu item ID from above
Thus far, here's what I have with ToolbarButton32:
--get IE's hWnd
--find the ToolbarWindow32 of interest, using EnumChildWindows
--get the "File" toolbutton, using SendMessage with TB_GETBUTTON; this gives
me its "command ID"
Now I don't see a function/message to get the "Open" toolbutton, which is a
sub-button of File.
Would somebody point out what I should be doing?
Thanx
--A