Does a Crystal Reports report have to be bound to real data to create it?
Posted on 2007-04-06
I'm having a few problems with Crystal Reports, but I'm trying to solve them one at a time. There doesn't seem to be a good source of info out there specific to using Crystal Reports from a completely unbound Access application. I see some code snippets here and there, but no good overall resource. If anyone can point me to one that I find very helpful, I'll start a second thread and assign another 500 points to that person.
Currently, my problem is I cannot seem to create a report that allows for fields that have not yet been created. When I originally create the report, I have to bind it to a stored procedure, table or view (I using SQL Server for all my data) to add the fields to the report. When I call the report from within Access, I change all these data sources on the fly since we utilize more than one data source with duplicate structures. What I want to be able to do is add fields to the ADODB Recordsets in Access and have these fields show on the report. I cannot add these fields to the report, however, since they do not exist in the original data source when the report is designed from the start (I'm sure I can, I just don't know how). When I try to add a field to the report that does not exist in the data source, I get an error saying "This field name is unknown". I understand that it is unknown to Crystal Reports when I add it, but the field will be known when I attach the ADODB recordset when the report is actually run. How can I overcome this?