Just throwing out some ideas...if the report is part of an application you could write the settings to the user's registry, or to a file that you read before running the report, or to a table in the database.
Good luck.
It sounds like you need to open the connection to the database, or specify connection information, i.e. user_id, password, server, etc.
I don't ususally connect through Crystal so I don't know the exact syntax, but I think there's a .LogOnInfo property that you can user to specify that. I...
...know how to trap for an Oracle error inside the function.
Anyone?
CREATE OR REPLACE FUNCTION IsNumber
(
psString VARCHAR2
)
RETURN NUMBER
IS
n NUMBER;
BEGIN
/* Need to trap for error 06502 - conversion error and return 0 if it occurs*/
n := TO_NUMBER(psString);
RETURN -1...
...difference in field types or other constraints. You can fill your tables like so:
oOleCmd.CommandText = "Select * from table1"
oOleDA.Fill(ds, "table1")
oOleCmd.CommandText = "Select * From...
I've got a .NET application that includes crystal reports. The problem I have on 1 machine is that when the user drills down and I open another crystal report in a new window (target = _blank) I get an empty window. Naturally, it works fine on all the other machines.
It's IE 6.0 with SP1 but...
In Crystal for Visual Studio .NET the ReportDocument object has a .SetDataSource property that allows you to pass a recordset. There's also a Reportdocment.Database.Tables(0).SetDataSource for passing a recordset to an individual table.
Hope that helps.
Trying to export an on-demand subreport, i.e. a user clicks the link that displays the sub-report, when I execute .Export() the main report, not the subreport, exports!
If I call .Export on the subreportobject I get "Error: Missing parameter field current value".
Any ideas anyone?
If you CAN I've never seen it done. Why not do it in your application after running your report?
In psuedo code something like....
Sub Button_Click()
Report1.Show
SQL = "Update table1 set blahblah = 'abc';"
Connection.execute SQL
End sub
In an ASP.NET app that I have I can do the following to print a report:
Dim Rep as new CrystalReport1
'Open the report first
.
.
'This is the name of the printer as it is defined on the server
Rep.PrintOptions.PrinterName = "Hp_laserjet1"
Rep.PrintToPrinter(1, False, 1, 999)
It sounds like you need to filter the data to limit the number of records you're returning. Maybe add some parameter fields where a user can enter a date range or range of customers??
I don't do alot of SQL from within Crystal but if I recall correctly you can open and edit the SQl window in crystal. If that's the case you can just type the Union query you need, e.g. Select Field1, Field2 From table1 Union Select Field1, Field2 From table2;
...the report to the project.
Dim rep as new CrystalReport1
OleDbDataAdapter1.TableMappings.Clear()
OleDbSelectCommand1.CommandText = "Select * From cost_centers Where Id=1234 And Name Like 'Bush*'"
OleDbDataAdapter1.Fill(DS1, "cost_centers")
rep.SetDataSource(DS1)
With...
I believe you need to put it in the group footer so it will reset with each group. It has to go in the footer so that it will count everything.
Also in Crystal .net you can create a Summary field and specify that it resets with a particular group (you indicate the group) on the property page.
Just deployed an ASP.NET application and everything except Crystal Reports works fine. Naturally it works fine on the development machine and even on another test machine; it's just production that's hosed! Anyone ever get the following error when you try to open the Crystal web report viewer...
You could put a viewer on each tab. If you have alot of tabs that might not be efficient, though. If that's the case you might try reusing a viewer by simply changing the ReportSource property.
I've got an ASP.NET application that uses a half dozen crystal reports. It's in VB not C#, but you should be able to follow it since the basic premise requires little code.
The way I did it is...
Create a report(s) in the project. Then add a webform with the crystalreportviewer control. In...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.