assigning recordset to a form

J

joy

My Form has a recordset based on a sql query and a
recordset is made using DAO method.After modifying the
above recordset using DAO method, I would like to
reassign this recordset back to the Form to reflect the
changes.Could somebody help me how to assign a recordset
to a form or report?
 
L

Larry Linson

If you have updated the underlying data, what you want to do is to requery
the Form, not to assign a recordset to it. Assuming that you have modified
the recordset in code in the Form's Module, Me.Requery will do what you
want. If you update from a Standard Module then, assuming the Form is open,
Forms!nameofyourform.Requery.

If it is needful to relocate to the same record that was shown before the
requery, post back here with the name of the Field that contains the unique
ID of the Records, and the name of the Control in which that is displayed.

Larry Linson
Microsoft Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top