What else fires when the user clicks on the down-arrow of the combo?I am not sure GotFocus event is the best one for what you are trying to do.
I understand your description of making the image form Modal. It's the same situation as if I open it Dialog, in which case the user would have to close the image form before any other user action.
Why do you need action on click of dropdown? Why not AfterUpdate event?
Have to close or set not visible. Basically same result from user perspective.
Opening with acDialog doesn't seem to be quite the same as setting Modal property. When I use acDialog, can't seem to programmatically set Visible property. I can with Modal property set to yes.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Because to make the appropriate choice among the dropdown list requires simultaneous viewing of the image, hence pop the image up when the down-arrow is detected.Why do you need action on click of dropdown? Why not AfterUpdate event?
So, at 4AM this morning I said to myself, "dah self, replace the combobox with bound a text box and put the choice selection right in the image form and open the form dialog!".
So user had to click combobox to trigger form popup? I try to build forms so user doesn't have to leave keyboard during data entry.
Glad you found an alternative.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Bill
You asked me to look at post #12 though you since seem to have found the problem
For info, although it will still work, you don't need the Form in Forms!frmImSample.Form.Visible = True
You can bring an object to the front in design view using DoCmd.RunCommand acCmdBringToFront
Or you need to set focus on the object in a form to bring it to the front: Me.ObjectName.SetFocus
AFAIK, DoCmd.RunCommand acCmdBringToFront applies to controls on form, not form itself, and only works when form is in design view:
Me.tbxItemSearch.InSelection = True
DoCmd.RunCommand acCmdBringToFront
In my test, programmatically setting focus on control in form does not bring the form to front.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
How abou this:AFAIK, DoCmd.RunCommand acCmdBringToFront applies to controls on form, not form itself, and only works when form is in design view:
Me.tbxItemSearch.InSelection = True
DoCmd.RunCommand acCmdBringToFront
In my test, programmatically setting focus on control in form does not bring the form to front.
DoCmd.SelectObject acForm, "frmLocal" 'bring to front
Yes- that's what I said in the previous postAFAIK, DoCmd.RunCommand acCmdBringToFront applies to controls on form, not form itself, and only works when form is in design view:
Me.tbxItemSearch.InSelection = True
DoCmd.RunCommand acCmdBringToFront
In my test, programmatically setting focus on control in form does not bring the form to front.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.