SetFocus

J

John

How can I set the focus to a field (fld1) that has an
Input Mask? fld1.Setfocus doesn't work on it.

Thanks a lot.
-John
 
K

KeejToe

The .SetFocus method should work, even if the field has an input mask. Check other
properties of the field.
Do you get an error message?
 
D

DanK

There's limitations to the SetFocus command. For example,
you can't use it to move from a subform to the parent
form. Try using the GoToControl command. If that doesn't
work, email me.
 
A

Allen Browne

In what event are you attempting this?

My guess is that this is a timing issue, e.g. you are trying to do it when
it can't be done, or just before Access moves the focus elsewhere so it does
not achieve the desired result.
 
D

Dirk Goldgar

DanK said:
There's limitations to the SetFocus command. For example,
you can't use it to move from a subform to the parent
form.

??
You can't SetFocus to the parent form itself, but you can SetFocus to a
control on the parent form; e.g.,

Me.Parent!txtID.SetFocus
 

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