Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Command Bars
  New Posts New Posts RSS Feed - How do I hide Drop Down Triangle on Control Popup
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

How do I hide Drop Down Triangle on Control Popup

 Post Reply Post Reply
Author
Message
LeeHayton View Drop Down
Senior Member
Senior Member
Avatar

Joined: 25 November 2005
Location: United Kingdom
Status: Offline
Points: 102
Post Options Post Options   Thanks (0) Thanks(0)   Quote LeeHayton Quote  Post ReplyReply Direct Link To This Post Topic: How do I hide Drop Down Triangle on Control Popup
    Posted: 18 December 2006 at 12:21pm

When I use a controlpopup button to display a menu it shows the drop down triangle next to the icon.  How do I turn it off?

Thanks
Lee
 
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 19 December 2006 at 8:43am
Hi,
instead xptControlPopup use xtpControlButtonPopup...
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
LeeHayton View Drop Down
Senior Member
Senior Member
Avatar

Joined: 25 November 2005
Location: United Kingdom
Status: Offline
Points: 102
Post Options Post Options   Thanks (0) Thanks(0)   Quote LeeHayton Quote  Post ReplyReply Direct Link To This Post Posted: 19 December 2006 at 10:08am
Thanks for that Oleg - it works fine.
 
I am trying to mimic a calendar type popup control - by using a command bar and adding a calendar within a picture box to a xtpcontrolcustom.  (If I just use the handle of the Calendar control it dissapears when you click on it.)
 
    Dim cbcc As CommandBarControlCustom, cbb As CommandBarButton, cbp As CommandBarPopup
       
    Set cbcc = .ActiveMenuBar.Controls.Add(xtpControlCustom, ID_TEXT1, "")
        cbcc.Handle = Text1.hwnd
        cbcc.Flags = xtpFlagControlStretched
    
    Set cbp = .ActiveMenuBar.Controls.Add(xtpControlButtonPopup, ID_DatePickerDropDown, "")
        cbp.Style = xtpButtonIcon
        cbp.IconId = 1
        cbp.ToolTipText = "Select a date from the calendar."
        Set cbcc = cbp.CommandBar.Controls.Add(xtpControlCustom, ID_DatePicker, " ")
            cbcc.Handle = picDatePicker1.hwnd
            cbcc.Style = xtpButtonAutomatic
 
When I click the value on the calendar it puts it in the text box but then i need to close the expanded menu to hide the calendar.  I do this by executing the command button and then setting the focus to the text box.
 
    Text1 = DatePicker1.Selection.Blocks(0).DateBegin
    Dim cbp As CommandBarPopup
    Set cbp = cbToolbar.FindControl(, ID_DatePickerDropDown)
        cbp.Execute
    Text1.SetFocus
However, my problem is this - the calendar button still retains the highlight box (focus rectangle) around it until you hover the mouse back over the control.  How do I get rid of this and am I going about this the wrong way?
 
 
Thanks again
Lee
 
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.

This page was generated in 0.109 seconds.