How to remove focus from Form element when other elements exist

Posted on 2004-05-03
Last Modified: 2012-08-14
In MSaccess 97 I have a form with no elements that can receive focus (only images and text). When a user presses a button a picklist is made visible and the focus is set on the picklist. When the user is done with the picklist I want to hide the list again but it won't let me set visible = false because the picklist has the focus. I have no other form element to set the focus to.

Is it possible to do something like:  picklist.setfocus = false? When I load the form for the first time there's no element that has the focus. So it should be possible to remove the focus from the only form element that can have focus.

Question by:camjai
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2

Author Comment

ID: 10977135
(the buttons on my form are also images)
LVL 100

Accepted Solution

mlmcc earned 100 total points
ID: 10982985
You may be able to setfocus to the form itself.


If that doesn't work create a small textbox and set focus there then make your picklist invisible.

The textbox can be hidden by one of the images it just needs to be visible and enabled.


Author Comment

ID: 10984250
I tried setting focus to the form as you suggested:

none did the trick. I also tried overlaying the textbox with an image but as soon as it gets the focus, the textbox goes solid white and the cursor starts blinking inside it.
LVL 100

Expert Comment

ID: 10985494
Make the textbox small and set the background color to the same as the form.  Maybe leave it uncovered.

LVL 100

Expert Comment

ID: 11684688
Glad I could help


Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question