refresh or requery recordset

J

Jason

Hi,

I'm having trouble with refreshing or requery a recordset.

I have two forms where there recordset is build up through an ado
connection. The first form is a continueous form and the second form a
detailed form.

If i update some data on the second form i need to refresh the data on the
first form. Before i used me.requery or refresh but that doesn't work on ado
based recordsets.

Anyone have solution?
 
R

Robert Morley

You might be running into a timing issue. Resolving them can be more than a
little tricky at times, but just as a test to see if that's the problem, pop
up a message box after updating the second form, count to about 5, then
click OK and continue on to the code that updates the first form (Me.Requery
should do fine). If the first form updates correctly now, then timing is
definitely your problem.

I never found any great solutions to this, so I'll let others address it who
might have better ideas than I ever came up with.



Rob
 
B

Bruce M. Thompson

I'm having trouble with refreshing or requery a recordset.
I have two forms where there recordset is build up through an ado
connection. The first form is a continueous form and the second form a
detailed form.

If i update some data on the second form i need to refresh the data on the
first form. Before i used me.requery or refresh but that doesn't work on ado
based recordsets.

You need to ensure that changes to the record in the second form have been
committed to the underlying table, otherwise there are no changes to be
reflected in the first form. You might try setting the second form's "Dirty"
property to "False" prior to causing the first form to requery.
 

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