Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Command Bars
  New Posts New Posts RSS Feed - Adding More Sub Control Popup
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Adding More Sub Control Popup

 Post Reply Post Reply
Author
Message
Khaled Eissa View Drop Down
Newbie
Newbie


Joined: 09 August 2013
Location: Cairo
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Khaled Eissa Quote  Post ReplyReply Direct Link To This Post Topic: Adding More Sub Control Popup
    Posted: 08 March 2017 at 11:24am
Hi all,

I'm trying to add sub Control Popup but can not add Control Button to it. it goes wrong to main Control Popup.
any help

What I want is like in these two images

two sub Control Popup 
I need to add Control Buttons to each one

here is my code

    Set ControlOptions = RibbonBar.Controls.Add(xtpControlPopup, 0, "Options")
    ControlOptions.Flags = xtpFlagRightAlign
    
    Dim Control2 As CommandBarControl
    
    Set Control = ControlOptions.CommandBar.Controls.Add(xtpControlPopup, 0, "Styles")
    Control.CommandBar.Controls.Add xtpControlButton, ID_OPTIONS_STYLEBLUE2007, "Office 2007 Blue"
    Control.CommandBar.Controls.Add xtpControlButton, ID_OPTIONS_STYLESILVER2007, "Office 2007 Silver"
    Control.CommandBar.Controls.Add xtpControlButton, ID_OPTIONS_STYLEBLACK2007, "Office 2007 Black"
    Set Control2 = Control.CommandBar.Controls.Add(xtpControlButton, ID_OPTIONS_STYLEAQUA2007, "Office 2007 Aqua")
    Set Control2 = Control.CommandBar.Controls.Add(xtpControlButton, ID_OPTIONS_STYLEBLUE2010, "Office 2010 Blue")
    Control2.BeginGroup = True
    Control.CommandBar.Controls.Add xtpControlButton, ID_OPTIONS_STYLESILVER2010, "Office 2010 Silver"
    Set Control2 = Control.CommandBar.Controls.Add(xtpControlButton, ID_OPTIONS_STYLEBLACK2010, "Office 2010 Black")
    Set Control2 = Control.CommandBar.Controls.Add(xtpControlButton, ID_OPTIONS_STYLESCENIC7, "Windows 7 Scenic")
    Control2.BeginGroup = True
    
    
    
    Dim Control3 As CommandBarControl
    Dim Control4 As CommandBarControl
 
    
     Set Control3 = ControlOptions.CommandBar.Controls.Add(xtpControlPopup, 0, "Skins")
     
     Control3.CommandBar.Controls.Add xtpControlPopup, 0, "Windows Skins"
     Control3.CommandBar.Controls.Add xtpControlPopup, 1, "Other Skins"

     Set Control4 = Control3.CommandBar.Controls.Add(xtpControlButton, ID_SKINOPTIONS_OTHER, "Blue")


I want to add blue to the first "Wisndows Skins"
& Black to "Other Skins"








Back to Top
olebed View Drop Down
Admin Group
Admin Group


Joined: 01 July 2014
Location: Ukraine
Status: Offline
Points: 841
Post Options Post Options   Thanks (1) Thanks(1)   Quote olebed Quote  Post ReplyReply Direct Link To This Post Posted: 10 March 2017 at 6:02am
Originally posted by Khaled Eissa Khaled Eissa wrote:

     Set Control3 = ControlOptions.CommandBar.Controls.Add(xtpControlPopup, 0, "Skins")
     
     Control3.CommandBar.Controls.Add xtpControlPopup, 0, "Windows Skins"
     Control3.CommandBar.Controls.Add xtpControlPopup, 1, "Other Skins"

     Set Control4 = Control3.CommandBar.Controls.Add(xtpControlButton, ID_SKINOPTIONS_OTHER, "Blue")

I want to add blue to the first "Wisndows Skins"
& Black to "Other Skins"


But you add "Blue" to "Skins" (Control3Smile 

 Set Control4Control3.CommandBar.Controls.Add xtpControlPopup, 0, "Windows Skins"
Set Control5 = Control4.CommandBar.Controls.Add(xtpControlButton, ID_SKINOPTIONS_OTHER, "Blue")
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.