If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#21
|
|||
|
|||
setting focus to 3rd subform
Now I am back to the original error: 2455 'You entered an expression that
has an invalid reference to the property form/report.' Did I do the code right? Given your bang tip, this looks correct. Me.Reservationfrm.Form.Jobfrm.Form.Invoicefrm.Form .AllowEdits = True Me.Reservationfrm.Form.Jobfrm.Form.Invoicefrm.Form .AllowAdditions = True Me.Reservationfrm.SetFocus Me.Reservationfrm.Form.Jobfrm.SetFocus Me.Reservationfrm.Form.Jobfrm.Form.Invoicefrm.SetF ocus Thanks again for helping me. "Pieter Wijnen" wrote: if you fire the sql the allowadditions will get bypassed but you can also set Me.Reservationfrm.Form.Jobfrm.Form.Invoicefrm.Form .AllowEdits = True and Me!Reservationfrm.Form.Jobfrm.Form.Invoicefrm.Form .AllowAdditions = True HTH Pieter Note: it is reccommended to use the . (dot) notation instead of ! (bang) in code, as it will at least throw an error at runtime. "redFred" wrote in message ... Very good! But, I don't know how to ensure that I code properly to ensure the new record is allowed. Help? "Pieter Wijnen" wrote: think we solved it there Pieter "redFred" wrote in message ... Hmmmm....maybe you gave me a hint. Jobfrm and its subform Invoicefrm are enabled and unlocked. However -- maybe this? -- data entry is NO for Jobfrm and Invoicefrm. This fails with 2105 "You can't go to specified record." Me![Reservationfrm].SetFocus Me![Reservationfrm].Form.Jobfrm.SetFocus Me![Reservationfrm].Form.Jobfrm.Form.Invoicefrm.SetFocus Hoping this sheds light, while I thank you for the help. |
Thread Tools | |
Display Modes | |
|
|