Print Page | Close Window

How to Copy a group to a different tab?

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=16725
Printed Date: 05 July 2024 at 1:59am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: How to Copy a group to a different tab?
Posted By: Holsy
Subject: How to Copy a group to a different tab?
Date Posted: 19 May 2010 at 12:30pm
I am having trouble coping a CXTPRibbonGroup to a different CXTPRibbonTab. It seems that when I call CXTPRibbonGroup::Copy some of the group's member variables are reset and I wasn't expecting that. Here is what I am doing. Maybe there a different way to accomplish this?
 
CXTPRibbonGroups* pCXTPRibbonGroups = pSomeOtherTab->GetGroups(); //Not the same tab that pCXTPRibbonGroupToCopy is in.
CXTPRibbonGroup* pCopiedGroup = pCXTPRibbonGroups->InsertAt( nInsertAfterIndex, "Copied Group", nInsertId );
if( pCopiedGroup )
{
    pCopiedGroup->Copy( pCXTPRibbonGroupToCopy );
 
    // pCopiedGroup->m_pGroups is now set to pCXTPRibbonGroupToCopy->m_pGroups
    // This is not what I was hoping for. 
}
 



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