Got focus dropdown on tab control glitch

BJF

Registered User.
Local time
Today, 14:38
Joined
Feb 19, 2010
Messages
137
Hi, I found this thread listed a while back in 2005, but there were no replies, so I am bringing it up again because it is very annoying and hopefully soemone here know the solution.

"I sometimes use the standard Me.mycombo.Dropdown in the GotFocus event of a Combo Box.

I've noticed that when this is used with a Combo Box that is placed on top of a Tab Control and the user clicks the dropdown arrow on the Combo Box, the dropdown quickly flashes, but doesn't open, requiring the user to click the dropdown arrow again."

I tested it on a form without a tab and it functions properly.

Also it does work (dropdown) the first time, if I click not on the arrow, but in the combobox field instead.

Does anyone know how to workaround this problem so the dropdown, drops down, on the first click of the arrow.

Thanks,
Brian:banghead:
 
Sounds like a bug to me. What version of Access are you using?
 
BJF -

I think I had this same problem happen to me one time too. This should fix your problem (but I might be reading it wrong).

Private Sub cboItems_GotFocus()
With cboItems
.Dropdown
End With
End Sub

I hope that is the simple fix you need.
 
I tried your code Hkimpact, but it didnt make any difference.

I am uploading a sample database that clearly represents the problem i am talking about.

The combobox on the form has to be clicked twice on the arrow to dropdown because it has dropdown code on its got focus event.

However, it opens right up if you click in the field area instead.

And it works fine when tabbing with the keyboard, but i have cases where my ser would jump to a particular combobox with their mouse and it makes i confusing as well as seems
glitchy to have to click on the arrow twice to get the box to drop down.

Please look at the sample.
 

Attachments

Will someone please take a look at the attached sample database from my last post and help!

Thank,
Brian
 
Brian

I can not find a way to fix the problem that you have with the combo box. However, I have a “work-around” for you, if it helps. Take a look at the form called “frmWorkAround” in the attached db.
 

Attachments

Thanks alot for the response Bob,

I tried your workaround and it works fine.
I will try to implement it in my database where needed.

Brian
 
Glad to help. Post back if you have any problems.
 
maybe the original glitch was something to do with the tab getting the focus. as pat said, probably a bug with the tab control

note the (perhaps similar) bug with the "flicker" effect you get rolling over unattached labels in a tab control.

this problem is generally addressed by changing the label to an inactive text box.
 
Hello Gemma,
yes I'm definitely acquainted with some of the glitchy aspects of tab control, i got code from a site that runs in the command box to convert all labels to text boxes on the form at once!

I'm still running Access 2003. Do you have a later version? Does the tab control act the same with labels and with dropdown issues?

Thanks,
Brian
 

Users who are viewing this thread

Back
Top Bottom