View Full Version : recall previous testbox


NigelShaw
05-22-2008, 06:15 AM
Hi,

i did a search but didnt really find anything.
my current form has an apply button and a return button. When the return button is pressed, it checks the form for added data. if there is data, a message box appears to ask if you want to return to the form and apply or close the form without saving. if the user wants to return, i am trying to recall the last control that had the focus but cannot find a way to do it.

is there a way to do this?

regs,

nigel

DCrake
05-22-2008, 06:32 AM
Screen.PreviousControl.SetFocus

Is what you need.

NigelShaw
05-22-2008, 07:56 AM
many thanks.

NS