Click to See Complete Forum and Search --> : Problem encountered - Reports in VB 6.0


Jose
September 21st, 1999, 03:26 AM
I am finding lot of problem generating reports using Visual Basic 6.0 data report with Ms-Access 97 as backend.
1. I have generated few reports using Data Report control. The report gets all records when generated for the first time (Filtered by a value). The same report generated second time displays a all records except the last record. The filter value generated are correct only the last record is missing.
What can be the problem and solution for it.
2. Some times the recordset is cleared when the report is generated for the second time to clear the first time recordset. But it does not clear the recordset always. What can be the problem and solution for it.

Dr_Michael
September 21st, 1999, 03:35 AM
I have also found other problems with Data Reports (and posted here) but not these. Anyway, check your syntax, for example:

private Sub DataReport_Initialize()
If deYourDataEnvironment.rsYourRecordset.State = adStateOpen then
deYourDataEnvironment.rsYourRecordset.Requery
End If
deYourDataEnvironment.rsYourRecordset.Filter = "..." 'SQL here
End Sub




Michael Vlastos
Automation Engineer
Company Modus SA
Development Department