Log in

View Full Version : Solved: Form set focus



cath_hopes
11-07-2007, 03:53 AM
Hello - can anyone help with the this please?

The following code is initiated from a button on my Property Form. The Booking form opens but then focus returns to the Property Form. How do I set the focus to the newly opened Booking Form?

DoCmd.Openform "Booking Form", acNormal, , "Booking.[Property ID] = " & Me.Property_ID

Thanks!

OTWarrior
11-07-2007, 04:44 AM
change Me.Property_ID to
Frm_formname.Property_ID

Also, make sure that the previous form is made not visible, or make sure the opening form has "pop-up" enabled on it's properties.

cath_hopes
11-08-2007, 04:18 AM
Thank you OTWarrior !

Enabling the 'Pop-up' on the opening fom properties did the trick so I didn't tried making the previous form not visible.
I did try changing the DoCmd.Openform coding as you suggested but it returned the popup error 424 'Object Required'.

Catherine