Print Page | Close Window

How can I Change Ribbon Tab and Group Caption?

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=16101
Printed Date: 27 February 2025 at 5:21am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: How can I Change Ribbon Tab and Group Caption?
Posted By: jayH
Subject: How can I Change Ribbon Tab and Group Caption?
Date Posted: 28 January 2010 at 9:27pm
1. I want to change the caption,tooltip and description by using XML code.
2. I found ActionSample.
3. so I used below code.
======================================================================================================
After Ribbon CommandBar loading( CommandBar designer ) xml or xcb, Added below code.( i also called AfxOleInit() )
 

CXTPPropExchangeXMLNode px2(TRUE, 0, _T("Settings"));  

if (px2.LoadFromFile(_T("res\\Actions.ENG.xml")))       

{

XTP_COMMANDBARS_PROPEXCHANGE_PARAM param;

param.bSaveOriginalControls = FALSE;

param.bSerializeControls = FALSE;

param.bSerializeOptions = FALSE;

param.bSerializeLayout = FALSE;

param.bSerializeActions = TRUE;

GetCommandBars()->DoPropExchange(&px2, &param);      

pCommandBars->RedrawCommandBars();                       

}
====================================================================================================== 
Actions.ENG.xml is below.

<?xml version="1.0" encoding="EUC-KR"?>

<Settings CompactMode="1">

    <Actions Enabled="1">

      <Action Id="1023" Caption="Normal_Button" TooltipText="Button Tooltip" DescriptionText="This is Discrption"/>  // This is Ribbon Button. It works fine.

      <Action Id="1027" Caption="Home_Tab" KeyID="ID_HOME"/>                   // This is Ribbon Tab. This code doesn't work.

      <Action Id="1028" Caption="Home_Group1" KeyID="ID_HOME_Group1"/>    // This is Ribbon Home Group. This code doesn't work.

    </Actions>

</Settings>

======================================================================================================
I added 2lines(red color), But it doesn't work.
 
What's the Problem?
 



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net