Ribbonbar System Button  
       
      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=10349
       Printed Date: 03 November 2025 at 9:31pm Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com
      
 
  
      Topic: Ribbonbar System Button
       
      Posted By: Vulture
       Subject: Ribbonbar System Button
       Date Posted: 24 April 2008 at 12:42pm
       
      
        
          
	
Hope someone has a solution for this because I am going mad :)
  I have added a System Button and a CXTPRibbonControlSystemPopupBarListCaption to my ribbon bar like this:
 
  Dim rbarGeneral As XtremeCommandBars.RibbonBar Dim rbarPopup As XtremeCommandBars.CommandBarPopup
  Set rbarGeneral = cbarGeneral.AddRibbonBar("Standard")
  With rbarGeneral         .EnableDocking xtpFlagStretched         .EnableFrameTheme End With
  Set rbarPopup = rbarGeneral.AddSystemButton()         rbarPopup.Id = ID_OTHER_SYSTEMBUTTON         rbarPopup.Caption = "&Filer"
  With rbarPopup.CommandBar         Set rbarControl = cbarGeneral.CreateCommandBarControl("CXTPRibbonControlSystemPopupBarListCaption")             rbarControl.Caption = "Seneste regnskaber"             rbarControl.BeginGroup = True             .Controls.AddControl rbarControl End With
 
  This works perfectly .. But I then want to create a MRU in this SystemPopupBarList .. The only problem is that I do not know how to reference that group in code at a later time (it is easy to add the MRU entries if I do it right after creating the SystemPopupBarList .. However I would like to do the same whenever a file is opened or saved as well.
  So how do I reference that menu in code each time a file is loaded or saved so that I can add a new entry to it? 
          | 
         
        
      
 
  Replies: 
       
      Posted By: Vulture
       
      Date Posted: 24 April 2008 at 1:02pm
       
      
        
          
	
Never mind .. figured it out ... finally  
  Solution was simple:
  Set rbarPopup = cbarGeneral.FindControl("CXTPRibbonControlSystemPopupBarListCaption", ID_OTHER_SYSTEMBUTTON)
  Why is it that you always figure things out AFTER you have given up??? 
          | 
         
        
        
       
      
     |