Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Command Bars
  New Posts New Posts RSS Feed - Retaining Focus
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Retaining Focus

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

Joined: 13 April 2006
Status: Offline
Points: 168
Post Options Post Options   Thanks (0) Thanks(0)   Quote LittleJK Quote  Post ReplyReply Direct Link To This Post Topic: Retaining Focus
    Posted: 17 April 2007 at 3:57pm
Hi, we have a command bar that contains a combo box in which we want to keep the focus on the text inside the combo box whenever we hit enter. Currently when we hit enter it loses focus and then you have to click inside the drop down again. Is there anyway like using control notify event to keep the focus? We are using 10.42... possibly 11.1 will do the job?

Thanks
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 April 2007 at 1:26am
Hello,
try this
 
Private Sub CommandBars_CommandBarKeyDown(CommandBar As XtremeCommandBars.ICommandBar, KeyCode As Long, Shift As Integer)
    If KeyCode = 13 And Not CommandBar.SelectedControl Is Nothing Then
        If CommandBar.SelectedControl.Type = xtpControlComboBox Then
            KeyCode = 0
        End If
    End If
End Sub
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
LittleJK View Drop Down
Senior Member
Senior Member
Avatar

Joined: 13 April 2006
Status: Offline
Points: 168
Post Options Post Options   Thanks (0) Thanks(0)   Quote LittleJK Quote  Post ReplyReply Direct Link To This Post Posted: 18 April 2007 at 10:04am
Thanks... we'll see if that works out. 
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.