By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
426,234 Members | 1,832 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 426,234 IT Pros & Developers. It's quick & easy.

insert data from a form to another table

P: 25
hi...

i have a text box in the form, then i want the data is insert into another table.

thank you.
Feb 12 '09 #1
Share this Question
Share on Google+
3 Replies


Expert 100+
P: 1,287
How familiar are you with VBA code and SQL INSERT statements?
If not very familiar, we are going to need a lot more details.
Feb 12 '09 #2

Expert Mod 2.5K+
P: 2,545
Hi. We cannot answer your question as it stands as you have not told us nearly enough about the name of the table or query to which your form is bound, the name of the fields involved, what relation there is between the data on one form and the data you want to copy to. Please either expand what you are asking or advise us that you want your question deleted so we can remove it. Please also read the posting guidelines at the top of the forum.

Thank you.

MODERATOR
Feb 12 '09 #3

P: 25
thank you
i already found how to do it.

actullay i need to insert data from a form name "stock"
i have a text box
1. class
2. location
3. qty

i have to update the data in the stock table, and insert data from that 3 textbox into transaction table.

i already knew how.
here is the code i used to acces the table outside the form

Set db = CurrentDb
Set rs = db.OpenRecordset("select * from transaction")

rs.AddNew
rs!kelas = Me.class
rs!jml = Me.qty
rs!lokasi = Me.location
rs!tglInput = Date
rs!waktuInput = Time()
rs.Update

Set rs = Nothing

anyway, thanks for the response.
Feb 13 '09 #4

Post your reply

Sign in to post your reply or Sign up for a free account.