Add multiple new records to a subform

  • Thread starter Thread starter Mike Stephens
  • Start date Start date
M

Mike Stephens

I would like to add 10 new records to a subform automatically. The subform
has 4 fields and I need to put data into each field. Can someone please
explain how I can do this through code.

Regards,
Mike
 
Mike,

It will possibly be helpful for you to realise that forms or subforms
do not have records, data, or fields. These are the province of
tables. Forms provide an avenue whereby this data can be seen and
accessed. So, what you are really doing is adding your data to a
table or tables. For this, I would suggest an Append Query.

- Steve Schapel, Microsoft Access MVP
 
Steve Schapel said:
Mike,

It will possibly be helpful for you to realise that forms or subforms
do not have records, data, or fields. These are the province of
tables. Forms provide an avenue whereby this data can be seen and
accessed. So, what you are really doing is adding your data to a
table or tables. For this, I would suggest an Append Query.

- Steve Schapel, Microsoft Access MVP

If the data is always the same you can use an append query.

In your case a table with ten records that contain the information needed in
the fields and a calculated field that gets the key from the form.
 
Back
Top