Print Page | Close Window

How to get the pinning/unpinning functionality in

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=8840
Printed Date: 02 March 2025 at 3:28pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: How to get the pinning/unpinning functionality in
Posted By: mrmathis
Subject: How to get the pinning/unpinning functionality in
Date Posted: 20 November 2007 at 11:04am
I am trying to add an MRU list similar to office 2007(word)

 

Here is the initial code snippet that I have…

 

if (CXTPControlPopup* pControlSystem = pRibbonBar->GetSystemButton())

{

if (CXTPCommandBar* pCommandBar = pControlSystem->GetCommandBar())

{

    if (CXTPControls* pControls = pCommandBar->GetControls())

    {

        CXTPControl* pNewButton = pControls->Add(xtpControlButton,ID_FILE_NEW);

        //other buttons

 

        //mru list

        CXTPRibbonControlSystemPopupBarListCaption* pMRULabel = new CXTPRibbonControlSystemPopupBarListCaption();

        pMRULabel->SetCaption("Recent Documents");

        pMRULabel->SetBeginGroup(TRUE);

        pControls->Add(pMRULabel);

        CXTPControl* pMRUFile1 = pControls->Add(xtpControlButton,ID_FILE_MRU_FILE1);

        pMRUFile1->SetCaption("&1 file1.doc");

        CXTPControl* pMRUFile2 = pControls->Add(xtpControlButton,ID_FILE_MRU_FILE2);

        pMRUFile2->SetCaption("&2 file2.doc");

here is the output…


 

How do I get the pinning/unpinning functionality ? Are there any samples on how to use XTP_ID_FILE_MRU or CXTPRibbonControlSystemRecentFileList? Do you support pinning functionality?



-------------
--Mike



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