Discussion Locked

Access 2k database

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
I created a complex scheduling and accounting DB for a client. I need to open a scheduling form with the previous forms information. Form 1 pulls form 1 table and and form 2 writes to a different table. I can populate the fields but they will not write to the form 2 table. Any help would be great.

5 replies

by donq

It sounds as though you need to develop a procedure using Visual Basics DAO for Access where you open both a target and source recordset??? Not much information above but the process is quite simple.

by mark phelan

The Solution is at your fingertips my friend...

Firstly lets set some constants.

the origional form is called frm_origional
The Data is contained ina cell called cell_data
the new form is caled frm_new
the data shoul dbe put into a cell called cell_new

within form 1 you need to add some VBA code to the new form, on load section. I'll leave you to find that.

the code would be somehting like.

frm_new.cell_new.value = frm_origional.cell_data.value (not .text)

Prety simple to start with isnt it.

ok now we have to address the problem of getting the data to write to the table.

Assuming you have added a database controll thingy on the form try this...

frn_new.dbname.recordset.

Now this will show you a whole bunch of options as you type the code.

Assuming you are filtering the recordset to display a single record, you could try something along the lines of

frm_new.dbname.recordset.update to force the record to update.

Good luck

This discussion is closed to new replies.