Click here to Skip to main content
15,901,035 members

Comments by nbtthief (Top 2 by date)

nbtthief 24-Jul-12 0:32am View    
My problem is exactly what i stated above. For example:

I create Ribbon app with 4 button, i use Ribbon editor toolbox (in VS10) to drag and drop it to RibbonBar. Then i create new class derive from CMFCRibbonButton that i call it NewButton, then i add to Ribbon Bar 2 NewButton button. but because that button is my own creation so it wont appear in Ribbon Editor tool box.

So i must add code myself in OnCreate(...), those code just right below this line
m_wndRibbonBar.LoadFromResource(IDR_RIBBON);

When in ribbon editor, i click on Test Button, the app appear but with only 4 button (normal button), 2 NewButton button isnt display. But when i compile and run it display properly include 2 NewButton button (i add event and do some code, everything work greatly).

The big problem here is it work great on win XP, when i compile and run on win 7, it only appear 4 normal button
nbtthief 11-Jul-12 3:18am View    
Thank for replying, as i said above, with my own created project, nothing happen if i dont add massage map button (they're grey out as disable, cant click or do anything). But with sample project RibbonGadget, i just add new button/control then compile and run, every new added button/control work normally (can click or do something not grey out).

First, i think may be it automatically add message map for new added button but when i use class wizard to check on new added button ID, nothing is bolded (ON_COMMAND and ON_UPDATE_UI_COMMAND is not used), i can add new message handler on that ID.

Actually, this is not affect my project too much, it just make me wonder why?
Thank for reading and suggesting your idea
I appreciate all your idea