Re: Subform - Add New Record
From: John Vinson (jvinson_at_STOP_SPAM.WysardOfInfo.com)
Date: 10/06/04
- Next message: anonymous_at_discussions.microsoft.com: "Re: Reinstalling Access 2002"
- Previous message: Mike Revis: "Re: Reinstalling Access 2002"
- In reply to: Peter Smith: "Re: Subform - Add New Record"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 05 Oct 2004 19:37:55 -0600
On Tue, 05 Oct 2004 22:45:28 GMT, "Peter Smith"
<psmith6@SparnBlock.bigpond.net.au> wrote:
>
>"John Vinson" <jvinson@STOP_SPAM.WysardOfInfo.com> wrote...
>> Private Sub cmdGoToNew_Click()
>> Me.subMySubform.SetFocus
>> DoCmd.GoToRecord acNewRecord
>> End Sub
>
>Excellent. I had to change that to acNewRec (must be for A97) but it works
>great - thanks so much. One other thing-
>
>When I was using a pop-up form for dataentry, I could use the OnClose event
>to check for saving ('if Dirty' before going back to switchboard). How is
>it best to do this on a subform as it doesn't close when you move off it to
>a different tab?
>
>- Peter
>
You can use the BeforeUpdate event of the Subform control. It only
fires if a record on the subform is dirtied and subsequently you try
to save it (say by moving off the subform).
John W. Vinson[MVP]
Join the online Access Chats
Tuesday 11am EDT - Thursday 3:30pm EDT
http://community.compuserve.com/msdevapps
- Next message: anonymous_at_discussions.microsoft.com: "Re: Reinstalling Access 2002"
- Previous message: Mike Revis: "Re: Reinstalling Access 2002"
- In reply to: Peter Smith: "Re: Subform - Add New Record"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|