Hi guys,
I'm using VC6 SP5 with MFC to create my application. I have a Framewindow and a Toolbar. I can dynamically set the toolbars buttons. BUT: Obviously Framewindow/Toolbar pairs have some kind of automation that when the parent window has no command handler ( ON_COMMAND() ) of the toolbar buttons command ID, the toolbar button is disabled. What a funny idea. I can dynamically create buttons, but not their command handlers, as I need a unique function for each... who was the genius that thought this plan up ? If you have any clue what I'm talking about and/or any helpful hints, demo sources, tutorials, please share.
Because dynamic buttons are no fun if I don't have a chance to enable them.
I surfed the .net, but nothing really dynamic came up. I need it to be really dynamic, not cheats like create a hundred and hope that's the limit. I need it to be customizable in the code, not by the user of my app.
I know I can create the button. I can set the command handler ID. But If I have no hard-coded command handler, the framework will disable the button.
Tearing my hair out already...
[Edit: If you know how to do it in API only, your welcome... I will write the Toolbar class myself if I have to, I just need those *#&% dynamic stuff... ]



LinkBack URL
About LinkBacks



