1.11M Members

VBA CODE in access 2007

 
1
 

hi,
im working on a small project on access 2007, i have a form that contains multiple textboxes ,and a save button. these textboxes are related to tables, so what i need is a code for that button to save the records in the textboxes in the tables and then show a msg box sayibg that the save processes is complete.
..
thank you very much....

 
0
 

Hi there,

Are you using Access VBA as your platform? or your just using access as your back-end and you have a form in VB6?

 
0
 

thanks very much for reply.
im using access 2007 forms, i created many tables with relations and created forms to with bound text boxes and button.
what im asking is i have a form have 5 text boxes and a button, the user should fill the data and press on the button which should save the records in the related tables.

 
0
 

here is my code:

Private Sub Command22_Click()
DoCmd.RunCommand acCmdSaveRecord
MsgBox "Data is saved", vbOKOnly, "E-car System"
End Sub
the problem is when the save button is pressed the text boxes remain with same records that are filled, THEY ARE NOT BLANK, they should be blank when the records are saved. PLEASE HELP ME

 
0
 

DoCmd.GoToRecord , , AcRecord.acNewRec
this is what i was missing,, thanks anyway for your help the problem is solved

Question Answered as of 3 Years Ago by neket
You
This question has already been solved: Start a new discussion instead
Post:
Start New Discussion
View similar articles that have also been tagged: