Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Command Bars
  New Posts New Posts RSS Feed - How can I Change Ribbon Tab and Group Caption?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

How can I Change Ribbon Tab and Group Caption?

 Post Reply Post Reply
Author
Message
jayH View Drop Down
Newbie
Newbie
Avatar

Joined: 28 January 2010
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote jayH Quote  Post ReplyReply Direct Link To This Post Topic: How can I Change Ribbon Tab and Group Caption?
    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?
 
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.156 seconds.