T TomJamieson Registered User. Local time Today, 14:07 Joined Jun 8, 2006 Messages 50 Oct 6, 2006 #1 I want to have a button that will create a new record in my table, and populate a couple of the fields with certain data. Is there a way I can do this using vba?
I want to have a button that will create a new record in my table, and populate a couple of the fields with certain data. Is there a way I can do this using vba?
E ejstefl Registered User. Local time Today, 14:07 Joined Jan 28, 2002 Messages 378 Oct 6, 2006 #2 On the click event of your button, use: DoCmd.GoToRecord , , acNewRec to go to a new record. Then you can use: me.txtField1 = "Value1" me.txtField2 = "Value2" and so on to set values of certain fields.
On the click event of your button, use: DoCmd.GoToRecord , , acNewRec to go to a new record. Then you can use: me.txtField1 = "Value1" me.txtField2 = "Value2" and so on to set values of certain fields.