Hi All,
I have a website (created using C# with Visual Studio .NET 2002) which, among other things, allows users to print reports. The available reports were created using Crystal Reports 10.
This is what I'm doing to display the reports:
- Report1 is the class created by Visual Studio and a given report (in this case Report1) is added to the project.
- reportViewer1 is the name of the CrystalReportsViewer object that is used to view the reports online.
- "table1.id=" [criteria] is the selection formula of the report. table1 is a table on the database and criteria is the id that correspond to the record of this table that the user is iterested in.
The problem with the code above is that the report being displayed by the viewer contains either no data, or the data that was saved with the report. I thought that this had to do with the fact that the option "Save Data with Report" is selected on for the report, thus when the report is saved, the data that I'm viewing is also saved with it. So I opened the report and deselected that option so that no data would be saved with the report. When I run the site, and I try to view the report, I get a page that says "The Report you requested requires further information" and it contains the following fields:
Server Name: MySQLODBC
Database Name: [blank]
UserName: Jose
Password: [blank]
After these fields, I the page contains LogOn button. I mean, what is going on here?
Oh and one more thing: Of all 4 fields, I can only edit the Password one, so I entered a password in and clicked LogOn but the page is simply refreshed.
The data the report is supposed to display is stored on a MySQL Server database.
Does anyone have any idea what the problem is?
Thanks!
JC
_________________________________________________
To get the best response to a question, read faq222-2244.
I have a website (created using C# with Visual Studio .NET 2002) which, among other things, allows users to print reports. The available reports were created using Crystal Reports 10.
This is what I'm doing to display the reports:
Code:
[green]// C# code[/green]
Report1 rpt = new Report1();
rpt.RecordSelectionFormula = "table1.id=" [criteira];
reportViewer1.ReportSource = rpt;
- reportViewer1 is the name of the CrystalReportsViewer object that is used to view the reports online.
- "table1.id=" [criteria] is the selection formula of the report. table1 is a table on the database and criteria is the id that correspond to the record of this table that the user is iterested in.
The problem with the code above is that the report being displayed by the viewer contains either no data, or the data that was saved with the report. I thought that this had to do with the fact that the option "Save Data with Report" is selected on for the report, thus when the report is saved, the data that I'm viewing is also saved with it. So I opened the report and deselected that option so that no data would be saved with the report. When I run the site, and I try to view the report, I get a page that says "The Report you requested requires further information" and it contains the following fields:
Server Name: MySQLODBC
Database Name: [blank]
UserName: Jose
Password: [blank]
After these fields, I the page contains LogOn button. I mean, what is going on here?
Oh and one more thing: Of all 4 fields, I can only edit the Password one, so I entered a password in and clicked LogOn but the page is simply refreshed.
The data the report is supposed to display is stored on a MySQL Server database.
Does anyone have any idea what the problem is?
Thanks!
JC
_________________________________________________
To get the best response to a question, read faq222-2244.