SetFocus Problem

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm using sql 2000 and Access 2003.

I have a TripDate field and in the AfterUpdate I have code when a past date
is entered the user receives a message to enter a current date. The user
presses OK and the TripDate field clears. That part works fine but I can't
get the SetFocus to work.

After the user presses OK the cursor jumps to the TripTime field even though
I have TripDate.Setfocus. The TripDate Auto Tab is set to No.

Can anyone tell me how to set the focus on the TripDate field?

Thanks,

Paul
 
Move the SetFocus code into the LostFocus event of the control.

AfterUpdate is too early for the SetFocus to work.
 

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

Similar Threads

Subtract a year 2
MsgBox problem 22
Query on Date 8
Confusing quotation marks from ADO .NET to stored procedures 3
Setfocus problem 4
SetFocus Problems 2
SetFocus not working properly 4
setfocus 3

Back
Top