tags:

views:

106

answers:

2

I just added a CMFCRibbonEdit to my ribbon but it seems it does not get the focus.

It appears disabled.

I even copy/pasted an implementation of the creation of this control from a Microsoft sample but I get the same behaviour.

Any idea on what I may be doing wrong or forgetting to do ?

+1  A: 

Have you added an update handler for that ribbon element ID?

Check the RibbonGadgets and MSOffice2007Demo samples in the MFC Feature Pack to see how they do it.

The RibbonGadgets one will show you the exact code you need to use in order to add an element of the specified type to your ribbon.

demoncodemonkey
As mentioned I copy/pasted code from these two examples.I just copied the creation code.You talk about an update handler, could you elaborate please?
Fabien Hure
A: 

democodemonkey though it correctly. The ribbon elements need to all have an update handler, even a dummy one. If they do not they are disabled.

Now everything work perfectly.

Fabien Hure
So please can you accept my answer then :D
demoncodemonkey