CXTPControlPopupColor - Single button |
Post Reply |
Author | |
rupert
Newbie Joined: 28 August 2007 Location: United States Status: Offline Points: 13 |
Post Options
Thanks(0)
Posted: 30 August 2007 at 4:29pm |
Is it possible to get a regular popup which can reflect the color selected in the picker?
CXTPControlPopupColor creates a split-button color control. I don't want it to be a split button.
Thanks.
|
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hi,
As quite weird trick you can add standard popup button + hidden CXTPControlPopupColor with same id.
change Color property of hidden CXTPControlPopupColor and it will change icon of your popup. Think can work.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
rupert
Newbie Joined: 28 August 2007 Location: United States Status: Offline Points: 13 |
Post Options
Thanks(0)
|
Thank you for the suggestion however I am unable to make it work. The icon color does not update. It remains the same.
|
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
This code work for me. Try also add RedrawBar in yours.
Private Sub CommandBars1_Execute(ByVal Control As XtremeCommandBars.ICommandBarControl)
If (Control.Id = 101) Then CommandBars1.ActiveMenuBar.Controls(1).Color = vbGreen CommandBars1.ActiveMenuBar.RedrawBar End If End Sub Private Sub Form_Load()
Set CommandBars1.Icons = ImageManager1.Icons
Dim ControlPopup As CommandBarPopup Set ControlPopup = CommandBars1.CreateCommandBarControl("CXTPControlPopupColor")
ControlPopup.Visible = False CommandBars1.ActiveMenuBar.Controls.AddControl ControlPopup ControlPopup.Id = 100 ControlPopup.Color = vbRed Set ControlPopup = CommandBars1.ActiveMenuBar.Controls.Add(xtpControlPopup, 100, "Icon")
ControlPopup.Style = xtpButtonIcon CommandBars1.ActiveMenuBar.Controls.Add xtpControlButton, 101, "Change"
End Sub |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
rupert
Newbie Joined: 28 August 2007 Location: United States Status: Offline Points: 13 |
Post Options
Thanks(0)
|
Thank you, that works perfectly. I was failing to add the control to the command bar.
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |