Can't hide a task Ribbon Group?

Add-in Express™ Support Service
That's what is more important than anything else

Can't hide a task Ribbon Group?
 
Jason Coley




Posts: 272
Joined: 2005-05-26
I have the following code in the OnADXNewInspector of the TadxOutlookAppEvents, and also tried in the OnADXNewInspector of the TadxOlFOrmsManager.

with AladTP.rbTask.Controls do
begin
(Items[0] as TadxRibbonGroup).Visible := not bShow; //Old Manage Tasks group
(Items[1] as TadxRibbonGroup).Visible := bShow; //Project Options
end;

the first control is the Manage Tasks group, the second is my own group, it will only show if I have my custom form shown, which is dependant on the type of message class.

I have set the the IdMso to 'ManageTaskGroup' in the ribbon group I am trying to hide (Control 0).

Any ideas why this is happening?
Posted 06 Sep, 2010 15:39:00 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Hi Jason,

'GroupManageTask', not 'ManageTaskGroup'.


Andrei Smolin
Add-in Express Team Leader
Posted 08 Sep, 2010 11:37:41 Top
Jason Coley




Posts: 272
Joined: 2005-05-26
Sorry I entered it wrong in the forum, yes I have tried GroupManageTask, but still have the issue. The group just will not go away? This is using Outlook 2010.
Posted 08 Sep, 2010 14:47:39 Top
Ruslan Plakhuta




Posts: 76
Joined: 2008-07-01
Hi Jason!
Try to invalidate yout ribbon.
Set to your control visibility state and then invalidate a ribbon.
Something like that:


AladTP.rbTask.Controls.Items[1].AsRibbonGroup.visible := bShow;
AladTP.rbTask.Invalidate;
Posted 11 Sep, 2010 05:32:16 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Thank you, Ruslan.

Hi Jason,

No Invalidate is used in http://www.add-in-express.com/files/support/ShowHideBuiltinRibbonGroup.zip.


Andrei Smolin
Add-in Express Team Leader
Posted 13 Sep, 2010 07:44:54 Top