Focus from Form to Open Query

P

Peter Allanach

I have two open forms and an open query. I want to close
one of the forma and switch the focus to the query.
Instead it is defaulting to the other form. How do I
switch focus from the closing form to the open query so
that the user sees the queries results and not the second
form?
 
J

John Viescas

Giving the user access to a query datasheet in an application is not a good
idea. Why not design a form (even in datasheet view) bound to the query?
Then, it's easy to control the focus with:

Forms!MyDatasheetForm.Setfocus

--
John Viescas, author
"Microsoft Office Access 2003 Inside Out"
"Running Microsoft Access 2000"
"SQL Queries for Mere Mortals"
http://www.viescas.com/
(Microsoft Access MVP since 1993)
http://www.deanforamerica.com/site/TR?pg=personal&fr_id=1090&px=1434411
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top