Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Command Bars
  New Posts New Posts RSS Feed - CommandBarComboBox insertstext before EditHint
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CommandBarComboBox insertstext before EditHint

 Post Reply Post Reply
Author
Message
bobmazanec View Drop Down
Newbie
Newbie


Joined: 26 April 2007
Location: United States
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote bobmazanec Quote  Post ReplyReply Direct Link To This Post Topic: CommandBarComboBox insertstext before EditHint
    Posted: 17 July 2007 at 2:26pm
I have a CommandBarComboBox with these options:
.AutoComplete = True
.DropDownListStyle = True
.Style = xtpButtonCaption
.EditHint = "Some Hint"
When I click in the ComboBox, it selects the EditHint text.
If I insert or append characters -- instead of overwriting all of them -- it appears to keep the EditHint - e.g., .Text = "insertedSome Hint"
If I remove the inserted characters, the hint reverts to grey and .Text to ""
 
Is there an option or property to keep the .EditHint out of .Text unless the user really types it?
 
TIA,
bob
 
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


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: 18 July 2007 at 1:55am
Hello,
 
Sorry, I can't reproduce it with current release. What Commandbars version do you have?
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
bobmazanec View Drop Down
Newbie
Newbie


Joined: 26 April 2007
Location: United States
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote bobmazanec Quote  Post ReplyReply Direct Link To This Post Posted: 18 July 2007 at 9:43am
10.4.1 (somehow I've missed 11.x until now)
 
After further experimentation, it only seems to happen when I call the CommandBars' RecalcLayout in the ControlNotify handler.
 
I have reproduced it in a simple project w/ a single Form containing a CommandBars control:
Private Sub Form_Load()
    With CommandBars1.Add("commandbar", xtpBarTop)
        ConfigureComboBox .Controls.Add(xtpControlComboBox, 1, "")
    End With
End Sub

Private Sub ConfigureComboBox(ByVal cb As CommandBarComboBox)
    With cb
        .DropDownListStyle = True
        .EditHint = "Some Hint"
        .Width = 200
    End With
End Sub
 
Private Sub CommandBars1_ControlNotify(ByVal Control As XtremeCommandBars.ICommandBarControl, ByVal Code As Long, ByVal NotifyData As Variant, Handled As Variant)
    CommandBars1.RecalcLayout
End Sub
 
Back to Top
bobmazanec View Drop Down
Newbie
Newbie


Joined: 26 April 2007
Location: United States
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote bobmazanec Quote  Post ReplyReply Direct Link To This Post Posted: 18 July 2007 at 10:31am
I can't reproduce it on 11.1.3 Eval - thanks!
 
bob
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.047 seconds.