Jump to content

How to use _GUICtrlToolbar properly?


SupFlux
 Share

Recommended Posts

Hi dear helpers :-)

I want to add a button to an existing application that uses a ToolbarWindow32 component, like i.e. Outlook Express. So I think I can use the _GUICtrlToolbar* functions (from former Auto3Lib, now included in standard UDF) that come with AutoIt. I already handled to add separators and a new button to the toolbar (via _GUICtrlToolbar_AddButton function) but I do not know how I can handle clicks on that button.

It must (?) have something to do with the assigned CommandIDs, but they are not very well documented...

I also tried to setup a message loop, but never received any events from Outlook Express...

So I hope there is anyone out there, who can help me?

Thank you!

SupFlux

Link to comment
Share on other sites

I haven't used this new toolbar stuff yet but I would start at AutoIt helpfile. There are nice examples at ALL functions also at UDFs ones.

AutoIt helpfile is very good start point all the time :-)

But if somebody will post nice/simple example here I will be happy to read it/learrn from it too.

Edited by Zedna
Link to comment
Share on other sites

Meanwhile I got it nearly working. With GUIRegisterMsg() I registered for WM_COMMAND messages and changed (using _GUICtrlToolbar_SetParent()) the toolbars parent hWnd to my created Mini-Gui which is just meant as a receptor for those messages. So now I receive clicks on the toolbar and can handle them in my script. I still have to redelegate the catched messages to the original parent hWnd... hope that won´t be a problem.

I just don´t know if that is "the right" way to do it. Or if there is a different way intended that might be easier?

Thanks for your replies!

SupFlux

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...