
HELP with MS Report Writer and report not pulling current data
I hope I have not replied to this already, anyway, here is a code
snippet from an application that I am working on, place the code in
your DataReport Initialize Event, of course you will need to modify
it to suit your needs.. Henry
Private Sub DataReport_Initialize()
On Error GoTo Err
'if not open then open the recordset, needed only if the recordset has
never been initialized
DataConnODBC.rsSQLAmbDisc.Open
DataConnODBC.rsSQLAmbDisc.Requery
'refresh data for report
Exit Sub
Err:
'if the recordset has been opened then just refresh the data for the
report
DataConnODBC.rsSQLAmbDisc.Requery
End Sub
On Tue, 06 Oct 1998 16:52:16 GMT, "Robin Collins"
Quote:
>I am new at using MS's Report Writer and am having problems getting the
>report to pull the current data. The table being input is getting created
>correctly, but it continues to either show me old data, or no data at all.
>HELP!!!! I know that this is just a "Refresh" issue, but I don't know how
>to force the report to refresh the data before printing...