Set Focus to Detail Section

P

pwh777

I have a form with Header and Footer sections. I click a button in the
Footer section and want to set focus to the Detail section. But I want
the focus to go back to the control that had focus prior to when the
button was clicked. I don't want to use the LostFocus event on every
control. Is there anything like a Me.Detail.SetFocus (I tried this and
this one does not exist)?
 
M

missinglinq via AccessMonster.com

No, I don't believe there is a Detail.SetFocus. But there is this nifty
little command that does exactly what your heart desires!

Screen.PreviousControl.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