Hello,
I have already created a data environment with a connection to my back-end access database. Also I have made a data report that uses this connection to successfully display all records from one of the database tables.
Now I need to modify the data report so that it shows only search results returned in a DBGrid (the grid is bound to the DAO dat1). I have tried the following code:
But at runtime, this produces "Runtime Error 13: Type Mismatch."
Any ideas on how to correct this problem (maybe there are some other properties on the report that are incorrectly set?)?
Any help greatly appreciated
I have already created a data environment with a connection to my back-end access database. Also I have made a data report that uses this connection to successfully display all records from one of the database tables.
Now I need to modify the data report so that it shows only search results returned in a DBGrid (the grid is bound to the DAO dat1). I have tried the following code:
Code:
Private Sub cmdPrint_Click()
Set datareport1.DataSource = dat1.Recordset
datareport1.show
End Sub
Any ideas on how to correct this problem (maybe there are some other properties on the report that are incorrectly set?)?
Any help greatly appreciated