Crystal Report for Visual Studio .NET
 
Published: 10 Feb 2004
Unedited - Community Contributed
Abstract
An overview of Crystal Reports. Walkthroughs show how to use both Pull and Push methods as well as exporting the report file into other formats.
by Eric Landes
Feedback
Average Rating: 
Views (Total / Last 10 Days): 224450/ 262

Overview

Editor's Note: The first edition of this article was written by Ajay Varghese.

Before we started off this small research on Crystal Reports for Visual Studio .NET, my friend and I were inquisitive about the complexity with regard to its implementation into our web application. A week later, with a lot of effort going into hunting for the ‘how-to’ documentation online, we have managed to integrate some simple reports into our ASP.NET application and try some neat tricks with it!!

This article is a compilation of required material to kick-start the process of implementing Crystal Reports into your .NET web application and should reduce your frustrating efforts (spent for the same research that we made) to a trifle by using these step-by-step walkthroughs. To get the best out of this article, the reader should have a basic Knowledge of database connections in ASP.NET and use Visual Studio .NET for the development. Please note that we have tested the below given sample code illustrations with the beta 2 version of Visual Studio .NET only.

The topics that we have covered here are :

1) Introduction

2) Getting a feel of it - Using an existing Crystal Report file in your .aspx page

3) Crystal Reports Walkthrough - using the Pull Model

4) Crystal Reports Walkthrough - using the Push Model

5) Exporting the Report file into other formats

Introduction

Crystal Report comes in various flavors and the one that is required for building reports for .NET is "Crystal Report for Visual Studio .NET".  It exposes a rich programming model with which we could manipulate its properties and methods during runtime.  If you are developing your .NET applications using Visual Studio .NET then you won’t have to install any additional software as it is already built into Visual Studio .NET.

---- Advantages -----

Some of the major advantages of using Crystal Report for Visual Studio .NET are :

- Rapid report development

- Can extend it to complicated reports with interactive charts

- Exposes a report object model using which it can interact with other controls on the web form

- Can programmatically export the reports into widely used formats like .pdf, .doc, .xls, .html and .rtf

 

---- The Architecture ----

The various components that make up a simple implementation of Crystal Report as a 2-tier architecture, required for web applications are

The Client :

The client only needs a browser to access the reports which are embedded into the .aspx pages.

The Web Server hosts the :

- Crystal Report Engine (CREngine.dll)

Along with other tasks like merging the data with the report file, exporting reports into different formats, etc., it is the Report Engine that converts your Crystal Report into plain HTML that is passed on to your .aspx page.

- Crystal Report Designer (CRDesigner.dll)

The reports are created from scratch using the Crystal Report Designer, with which you could design the titles, insert data, formulas, charts, sub-reports, etc.

- The .rpt Report file

The first step to implement a report into your web application would be to create it using the Crystal Report Designer interface.  You will find some ready-made .rpt samples provided with the default installation.

- The Data Source

The way your .rpt file gets the data depends on which method you choose. You can choose to make Crystal Report itself to fetch your data without writing any code for it or you can choose to manually populate a dataset and pass it on to the report file. We will look at the various possibilities a little later in this article.

- Crystal Report Viewer web form Control (CRWebFormViewer.dll)

The Crystal Report Viewer control is a web form control that can be inserted into your .aspx page.  It can be thought of as a container that hosts the report on the .aspx page. 

Note : In a more complex implementation, the reporting server and the web server could be on different physical servers, where the web server would make an HTTP request to the reporting server.  The Crystal Reports could also be implemented as a web service.

---- Implementation Models -----

Fetching the data for the Crystal Report could be done by using any of the following methods :

- Pull Model :

where in Crystal Report handles the connection to the database using the specified driver and populates the report with the data, when requested.

- Push Model :

where it is the developer who has to write code to handle the connection and populate the dataset, and pass it on to the report.  The performance can be optimized in this manner by using connection sharing and manually limiting the number of records that are passed on to the report.

---- Report Types ----

Crystal Report Designer can load reports that are included into the project as well as those that are independent of the project.

- Strongly-typed Report :

When you add a report file into the project, it becomes a ‘strongly-typed’ report. In this case, you will have the advantage of directly creating an instance of the report object, which could reduce a few lines of code, and caching it to improve performance. The related .vb file, which is hidden, can be viewed using the editor’s ‘show all files’ icon in the Solution Explorer. 

- Un-Typed Report :

Those reports that are not included into the project are ‘un-typed’ reports.  In this case, you will have to create an instance of the Crystal Report Engine’s 'ReportDocument' object and manually load the report into it.

---- Other things you should know ----

-         Though the Crystal Report Viewer control comes with some cool in-built options like zooming, page navigation, etc., it does not have a custom print option. You will have to depend on the browser’s print feature.

-         An un-registered copy of Crystal Report for Visual Studio .NET will remain active only for the first 30 uses, after which the ‘save’ option will be disabled.  To avoid this, all you have to do is register the product with www.crystaldecisions.com for which you are not charged.

-         The default installation will service only 5 concurrent users. To support more users, you will have to buy additional licenses from www.crystalDecisions.com

Getting a Feel of It - Using an Existing Crystal Report File in Your .aspx Page

Lets take a look at how we could get this done the fast way to get a feel of how a Crystal Report file would look like in your web form.

1) Drag and drop the "Crystal Report Viewer" from the web forms tool box on to the .aspx page

 

2) Bring up the properties window for the Crystal Report Viewer control

3) Click on the [...] next to the "Data Binding" Property and bring up the data binding pop-up window

4) Select "Report Source" from the "Bindable properties" section on the left side

 

5) Select the "Custom Binding Expression" radio button, on the right side bottom of the window and specify the sample .rpt filename and path as

"C:\Program Files\Microsoft Visual Studio.NET\Crystal Reports\Samples\Reports\General Business\World Sales Report.rpt"(including the double quotes) and Click "ok"

 

Note : The ‘World Sales Report.rpt’ file is created as a part of Visual Studio .NET installation. If you have specified a different directory during installation then make necessary changes to the above specified path.

In a couple of seconds you should see the Report Viewer Control load a preview of the actual report during design time itself. The reason for the data being loaded during design time is that the report has been saved with the data.

The above steps actually insert the following code into your .aspx page :

<%@ Register TagPrefix="cr" Namespace="CrystalDecisions.Web" Assembly="CrystalDecisions.Web" %>

above the Page Directive and

<CR:CrystalReportViewer

id="CrystalReportViewer1"

runat="server"

Width="350px" Height="50px"

ReportSource='<%# "C:\Program Files\Microsoft Visual Studio.NET\Crystal Reports\Samples\Reports\General Business\World Sales Report.rpt" %>'>

</CR:CrystalReportViewer>

within the <FORM> section of the page.

6) Call the DataBind method, on the Page Load Event of the Code Behind file (.aspx.vb).

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs)       

DataBind()

End Sub

 

7) Save, build and run your page.

There !!! You have a web form page with a Crystal Report file embedded into it.

Crystal Reports Walkthrough - Using the Pull Model

We would be using the following steps to implement Crystal Reports using the Pull Model :

1. Create the .rpt file (from scratch) and set the necessary database connections using the Crystal Report Designer interface.

2. Place a CrystalReportViewer control on the .aspx page and set its properties to point to the .rpt file that we created in the previous step.

3. Call the databind method from your code behind page.

Creating the .rpt File:

1) Add a new Crystal Report to the web form by right clicking on the "Solution Explorer", selecting "Add" --> "Add New Item" --> "Crystal Report".

 

2) On the "Crystal Report Gallery" pop up, select the "As a Blank Report" radio button and click "ok".

 

 

3)This should open up the Report File in the Crystal Report Designer

 

 

4) Right click on the "Details Section" of the report, and select "Database" -> "Add/Remove Database"

 

5) In the "Database Expert" pop up window, expand the "OLE DB (ADO)" option which should bring up another "OLE DB (ADO)" pop up

 

6) In the "OLE DB (ADO)" pop up, Select "Microsoft OLE DB Provider for SQL Server" and click "Next"

 

 

7) Specify the connection information

          Server : HomePC (Make use of your server name here)

          User Id : sa

          Password :

          Database : Pubs

 

8) Click "Next" and then click "Finish"

 

9) Now you should be able to see the Database Expert showing the table that have been selected

 

10) Expand the "Pubs" database, expand the "Tables", select the "Stores" table and click on ">" to include it into the "Selected Tables" section.

 

 

11) Now the Field Explorer should show you the selected table and its fields under the "Database Fields" section, in the left window.

 

12) Drag and drop the required fields into the "Details" section of the report. The field names would automatically appear in the "Page Header" section of the report. If you want to modify the header text then right click on the text of the "Page Header" section, select "Edit Text Object" option and edit it.

 

 

13) Save it and we are through with the creation of the Crystal Report file !!

Creating a CrystalReportViewer Control

14) Back on the web form page, drag and drop a "Crystal Report Viewer" control from the "WebForms" tool box. (image shown in the previous example)

15) Bring up the properties window of the CrystalReportViewer control, Select Databindings and Click on [...]

 

16) In the "Crystal Report Viewer Databinding" pop-up window, select "Report Source" from the "Bindable Properties" section on the left side, Select "Custom Binding Expression" radio button on the right side bottom, and specify the file name with the path of the .rpt file (within double quotes).

 

 

17) You should be able to see the Crystal Report Viewer showing you a preview of actual report file using some dummy data and this completes the inserting of the Crystal Report Viewer controls and setting its properties.

 

Note : In the previous example, the CrystalReportViewer control was able to directly load the actual data during design time itself as the report was saved with the data. In this case, it will not display the data during design time as it not saved with the data - instead it will show up with dummy data during design time and will fetch the proper data only at run time.

 

Code Behind Page Modifications

18) Call the Databind method on the Page Load Event of the Code Behind file (.aspx.vb).

Run your Application

19) Build and run your .aspx page and you should be able to see your own report file embedded into the web page!!!

 

Note that you will have access to the built-in controls of Crystal Report like "Page Navigation", "Zoom", etc in your web page.

Crystal Reports Walkthrough - Using the Push Model

We would use the following steps to implement Crystal Reports using the Push Model :

1. Create a Dataset during design time.

2. Create the .rpt file (from scratch) and make it point to the Dataset that we created in the previous step.

3. Place a CrystalReportViewer control on the .aspx page and set its properties to point to the .rpt file that we created in the previous step.

4. In your code behind page, write the subroutine to make the connections to the database and populate the dataset that we created previously in step one.

5. Call the Databind method from your code behind page.

Creating a Dataset during Design Time to Define the Fields of the Reports

1) Right click on "Solution Explorer", select "Add" --> select "Add New Item" --> Select "DataSet"

 

 

2) Drag and drop the "Stores" table (within the PUBS database) from the "SQL Server" Item under "Server Explorer".

3) This should create a definition of the "Stores" table within the Dataset

 

- The .xsd file created this way contains only the field definitions without any data in it. It is up to the developer to create the connection to the database, populate the dataset and feed it to the Crystal Report.

Creating the .rpt File :

4) Create the report file using the steps mentioned previously. The only difference here is that instead of connecting to the Database thru Crystal Report to get to the Table, we would be using our DataSet that we just created.

5)After creating the .rpt file, right click on the "Details" section of the Report file, select "Add/Remove Database"

6) In the "Database Expert" window, expand "Project Data" (instead of "OLE DB" that was selected in the case of the PULL Model), expand "ADO.NET DataSet", "DataSet1", and select the "Stores" table.

7) Include the "Stores" table into the "Selected Tables" section by clicking on ">" and then Click "ok"

 

8) Follow the remaining steps to create the report layout as mentioned previously in the PULL Model to complete the .rpt Report file creation

 

Creating a CrystalReportViewer Control

9) Follow the steps mentioned previously in the PULL Model to create a Crystal Report Viewer control and set its properties.

Code Behind Page Modifications :

10) Call this subroutine in your page load -

    Sub BindReport()

        Dim myConnection As New SqlClient.SqlConnection()

        myConnection.ConnectionString= "server= (local)\NetSDK;database=pubs;Trusted_Connection=yes"

        Dim MyCommand As New SqlClient.SqlCommand()

        MyCommand.Connection = myConnection

        MyCommand.CommandText = "Select * from Stores"

        MyCommand.CommandType = CommandType.Text

        Dim MyDA As New SqlClient.SqlDataAdapter()

        MyDA.SelectCommand = MyCommand

 

        Dim myDS As New Dataset1()

       'This is our DataSet created at Design Time      

 

        MyDA.Fill(myDS, "Stores")  

 

        'You have to use the same name as that of your Dataset that you created during design time

  

        Dim oRpt As New CrystalReport1()

         ' This is the Crystal Report file created at Design Time

  

        oRpt.SetDataSource(myDS)

         ' Set the SetDataSource property of the Report to the Dataset

 

        CrystalReportViewer1.ReportSource = oRpt

         ' Set the Crystal Report Viewer's property to the oRpt Report object that we created

  

    End Sub

Note : In the above code, you would notice that the object oRpt is an instance of the "Strongly Typed" Report file. If we were to use an "UnTyped" Report then we would have to use a ReportDocument object and manually load the report file into it.

 

Run your Application

11) Build and run your .aspx page and you should be able to see your own report file embedded into the web page!!!

Exporting the Report File into Other Formats

You can opt to export your report file into one of the following formats :

             1. PDF (Portable Document Format)

1.                                 2. DOC (MS Word Document)

2.                                 3. XLS (MS Excel Spreadsheet)

3.                                 4. HTML (Hyper Text Markup Language – 3.2 or 4.0 compliant)

4.                                 5. RTF (Rich Text Format)

To see it in action, you could place a button on your page to trigger the export functionality.

Exporting a Report File Created using the PULL Model :

When exporting a report that was created using the PULL Model, Crystal Report takes care of connecting to the database and fetching the required records, so you would only have to use the below given code in the Click Event of the button.

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

 

        Dim myReport As CrystalReport1 = New CrystalReport1()

      'Note : we are creating an instance of the strongly-typed Crystal Report file here.

 

        Dim DiskOpts As CrystalDecisions.Shared.DiskFileDestinationOptions = New CrystalDecisions.Shared.DiskFileDestinationOptions()

  

 

        myReport.ExportOptions.ExportDestinationType = CrystalDecisions.[Shared].ExportDestinationType.DiskFile

         ' You also have the option to export the report to other sources

         ' like Microsoft Exchange, MAPI, etc.       

 

        myReport.ExportOptions.ExportFormatType = CrystalDecisions. [Shared].ExportFormatType.PortableDocFormat

        'Here we are exporting the report to a .pdf format.  You can

        ' also choose any of the other formats specified above.

 

        DiskOpts.DiskFileName = "c:\Output.pdf"

        'If you do not specify the exact path here (i.e. including

        ' the drive and Directory),

        'then you would find your output file landing up in the

        'c:\WinNT\System32 directory - atleast in case of a

        ' Windows 2000 System

 

        myReport.ExportOptions.DestinationOptions = DiskOpts

        'The Reports Export Options does not have a filename property

        'that can be directly set. Instead, you will have to use

        'the DiskFileDestinationOptions object and set its DiskFileName

        'property to the file name (including the path) of your  choice.

        'Then you would set the Report Export Options

        'DestinationOptions property to point to the

        'DiskFileDestinationOption object. 

 

        myReport.Export()

        'This statement exports the report based on the previously set properties.

 

End Sub

 

Exporting a Report File Created Using the PUSH Model :

When exporting a report that was created using the Push Model, the first step would be to manually create the connections and populate the Dataset, and set the Report’s ‘SetDataSource’ property to a populated Dataset (as shown in the Push Model example previously). The next step would be to call the above given Export code.

______________________________________________________________________________________________

 

Submitted by :

Ajay Varghese & Shankar N.S.

Sr. Software Engineers,

Jarvis Infotech 

Crystal Resources

Crystal Alliance



User Comments

Title: show me the blank report   
Name: Deep
Date: 2006-02-15 4:52:08 AM
Comment:
hi,
it's nice matirial but it ca't be display the field of database in crystal report . so tell me the process how i see database content on crystall report at run time.

tank you
Title: Always getting Logon failed error   
Name: Shikhar
Date: 2006-02-08 3:54:04 AM
Comment:
This is my 6th day working with Cryatal Report but still iam getting LogOnfailed error.Plz any body can help me.its urgent
Title: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.   
Name: Gaya
Date: 2006-02-08 12:19:39 AM
Comment:
Why am I getting this logon failed exception when I export the report generated by PUSH?

Logon failed.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[LogOnException: Logon failed.]
.F(String  , EngineExceptionErrorID 
)
.A(Int16 , Int32 )
.@(Int16 )
CrystalDecisions.CrystalReports.Engine.FormatEngine.GetPage(PageRequestContext reqContext)
CrystalDecisions.ReportSource.LocalReportSourceBase.GetPage(PageRequestContext pageReqContext)
CrystalDecisions.Web.ReportAgent.u(Boolean N)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()
Title: Populate dataset   
Name: Sona
Date: 2006-02-06 6:20:10 AM
Comment:
Using push model, how can I populate the dataset and feed it to the Crystal Report? Pls give the code for it.
Title: help me please   
Name: joy
Date: 2006-02-01 10:20:56 AM
Comment:
first of all i want to thank you for this article it is very helpfull and has a very good information.

i have this problem with Crystal when i'm trying to export it to PDf and it gives me this error "The file is damaged and could not be repaired" do you know how to solve this problem it is urgent and i will be very appreciated.

regards
Title: <@ Register tagprefix ="cr" getting crystaldecision.web as invalid   
Name: Benjamin
Date: 2006-01-25 2:42:29 AM
Comment:
When I am running a crystal report in visual studio.net 2005 I am getting an error in the <@Register > statement where it says crystaldecision.web as invalid
Title: Error on logon failed   
Name: venkatesh
Date: 2006-01-20 7:11:51 AM
Comment:
I have got one problem when i am using crystal report.that is logon failed .
i don't know why it appears
i have used asp.net/sqlserver
my mail id = mcanetvenkat@hotmail.com
Title: Export Crystal reports into rpt file   
Name: Dima
Date: 2006-01-19 9:30:34 AM
Comment:
Hi,
Yeas, you can save report with data. You can select file and then “save data with report” after that save the report and then can you export report s into rpt with data .
Good Luck!
Title: Crystal Report   
Name: Dima
Date: 2006-01-19 7:35:48 AM
Comment:
I have a graph in crystal. The search criteria is year and week. I want to result 20 weeks back in year 2005 also. If I write week 2 so i am take a results only week 1 and 2. Can you help me pleas how can i do.
I have search criteria now:
{@week}>=({?week}-19)and
{@year}= {?year}
Title: Export Crystal reports into rpt file   
Name: Shan
Date: 2006-01-18 5:13:06 AM
Comment:
Can we export Crystal reports into rpt with data?

Thanks
Title: LogOn error Solution   
Name: alz
Date: 2006-01-17 5:49:39 PM
Comment:
Try this:

1. Go to SQL Server Enterprise Manager / Security / logins / new login.../General / Name /
2. Add account - ASPNET(account for running the ASP.NET), you can change login properties according your needs
3. Add DataBind(); in page_load

Good Luck!
Title: sql join   
Name: minto
Date: 2006-01-17 11:33:19 AM
Comment:
not working if the query is a join
Title: loadsavereportexception   
Name: thangaraj selvam
Date: 2006-01-12 5:35:24 AM
Comment:
CrystalDecisions.CrystalReports.Engine.LoadSaveReportException: It failed in the load of the report.

in pull method it specifies the given line
crreport.SetDatabaseLogon("sa", "")

in push method it specifies the given line
oRpt.SetDataSource(myDS)
Title: Error   
Name: Richard
Date: 2006-01-06 12:59:53 PM
Comment:
When I try to add the control to the web form I get a gray box with red letters saying "Error Creating Control CrystalReportViewer1". I have VS .NET 2003 with Crystal Reports XI. Any ideas?
Title: push model export to pdf   
Name: vipin
Date: 2006-01-02 2:56:44 AM
Comment:
hi all,
how we export the crystal report usinh push model?
send me code in devs_vipin@yahoo.co.in

thanks in advance
Title: login failed error at myReport.Export()   
Name: vipin
Date: 2006-01-02 2:41:44 AM
Comment:
hi,
happy new yaer to all
very good article,but in exporting to pdf make some problem.
login failed error at myReport.Export()
the error is
CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

what i do?plz send an immediate solution to devs_vipin@yahoo.co.in

with regards
vipin
Title: LogOn Error   
Name: Steve O
Date: 2005-12-31 11:26:49 AM
Comment:
I have tried every method to correct the log on error that everyone is getting including those posted here and on MSDN. I still get the error.
I have concluded as I had in the past when using Crystal Reports that the reason for this problem is that Crystal Reports sucks. It has always sucked, and will probably suck into the future.
Hope this helps.
Title: An excellent article   
Name: Avi
Date: 2005-12-30 6:17:59 AM
Comment:
When I started to work with crystal report I read
this article and for my first step working with crystal report it was graet.
Title: setting background image   
Name: roy
Date: 2005-12-27 3:39:51 AM
Comment:
Hi can anyone help me?
Can anyone tell me how to set a background image on a crystal report?
if you can, mail me the answer: roy_devos@hotmail.com

thx in advance
Title: Crystal Report for Visual Studio .NET   
Name: D.P
Date: 2005-12-14 2:11:26 AM
Comment:
The step by step explanation is v good. With the push method, in the 7th step Im not getting the table name under ADO.NET.dataset1. How to get it. Why am i not getting the table name.Do let me know. Thanks in advance.
DP
Title: missing chart   
Name: ainul
Date: 2005-11-29 8:24:22 PM
Comment:
this article is great. it helped me understand crystal report for .NET. but i'm having a slight trouble with the chart, it refused to show itself. everytime i add a chart to my report, it's there during design time but during runtime, there's only a blank white box with the little red x at the top. am i missing a component?
Title: Solution for: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed   
Name: Imran Shaikh
Date: 2005-11-29 4:07:28 AM
Comment:
Here is the solution for CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

http://www.dotnetjunkies.com/Article/790775A0-C493-46D8-ABE0-40CA588D33D3.dcik
Title: Mrs   
Name: Sudha
Date: 2005-11-24 1:16:02 AM
Comment:
Good Article. Helped me through my first crystal report
Title: Crystal Report for Visual Studio.Net   
Name: Ronan
Date: 2005-11-16 7:33:17 AM
Comment:
Best guide I've found for someone new to Crystal reports in asp.net. Thanks for the help.
Title: help   
Name: aresun
Date: 2005-11-15 2:12:53 AM
Comment:
CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

Getting this error while calling the particular web form.

Also it could be fine if i could get some sample reports (setting the database connection during the run time and passing parameters to the report)

Thanks in advance
Mail id :- sundarg23@yahoo.com
Title: blank report   
Name: Vladimir
Date: 2005-11-14 12:27:18 PM
Comment:
Hi,
I followed the Push Method walk through, and i did everything as said. When i run my app. all i get is a blank report. I don't get any errors!
This is the code that i use:
string sql = "select * from psi_players";
SqlConnection conn = new SqlConnection(connS);
SqlCommand com = new SqlCommand(sql,conn);
com.CommandType = CommandType.Text;
SqlDataAdapter da = new SqlDataAdapter(com);
DataSet1 ds = new DataSet1();
da.Fill(ds,"psi_players");
int tes = ds.Tables[0].Rows.Count;
CrystalReport1 report = new CrystalReport1();
report.SetDataSource(ds);
CrystalReportViewer1.ReportSource = report;
CrystalReportViewer1.DataBind();

help anyone?
Title: Too Gud   
Name: Prashanth
Date: 2005-11-02 7:03:07 AM
Comment:
Hi guys....
This article is really very helpful for a beginnner to get to know about Crystal Reports in .NET.
Good Work....
Title: Good peice of Work   
Name: Amit Jain
Date: 2005-10-26 5:39:13 AM
Comment:
Its really vry nice article for begineers like me.I have tried through Pull method but there is some problem atlast I have got through Push methiod.

Good peice of article.
Title: LogOn error Solution   
Name: Kshitiz
Date: 2005-10-25 5:02:44 AM
Comment:
Solve that problem by using below code
write on Page loadthe following code either or make a function aaaaand call on page load

CrystalDecisions.Shared.TableLogOnInfo myLogin;
foreach (CrystalDecisions.CrystalReports.Engine.Table myTable in crpt.Database.Tables)
{
myLogin = myTable.LogOnInfo ;
myLogin.ConnectionInfo.Password = "sa" ;
myLogin.ConnectionInfo.UserID = "sa" ;
myTable.ApplyLogOnInfo(myLogin) ;
}
CrystalReportViewer1.ReportSource=crpt;
}
u will definetly come out of prob
Title: Crystal Report   
Name: Priya
Date: 2005-10-20 5:04:53 AM
Comment:
This material is good for beginners.
Title: Crystal Report   
Name: Selmiya
Date: 2005-10-16 5:28:32 AM
Comment:
Nice article! Great help for beginners
Title: about crystal report   
Name: vikas vyas
Date: 2005-10-15 2:10:20 AM
Comment:
that's nice work . it help me a lot in crystal report . thax for it.
vikas vyas
Title: Crystal Report for Visual Studio .NET   
Name: aplee
Date: 2005-09-23 5:21:34 PM
Comment:
I am attempting to use a single CrystalReportViewer and allow the user to select from a list of report to display on a ASP.NET Web Form? I can switch to different reports The only problem I encountered is once I loaded the first report, as long as sub-sequent reports have the same Record Selection Formula, it works fine, otherwise, error occurs because of field unknown or whatever. My question is, when the browser post back with a new report selection, why does the CRystalReportViewer retain the old SelectionFormula?
Title: no output...   
Name: Bhakti
Date: 2005-09-22 1:41:20 PM
Comment:
hi , using similar code when i try to run the application in the main window it just displays the toolbar(crystal report) without any data. I also cross checked whether the dataset works fine od not with datagrid
but there it works fine but not with the crystal report.

Please help me for this....
Its urgent....
Thanks in advance....
Title: Re: Comma Expected   
Name: Patrick
Date: 2005-09-16 4:17:53 PM
Comment:
Nice tutorial.

For the comma expected error...

BC30196: Comma expected


Look at the HTML code and make sure the ReportSource property is being assigned correctly .NET 2003 assigns this
ReportSource= "<%# PATH %>"

when it should be

ReportSource= '<%# "PATH" %>'
Title: problem   
Name: Crystal report at time of execution
Date: 2005-09-10 5:50:28 AM
Comment:
hi
i put the chart in a report which is in crystal report 9 ,and when i executed on net the chart was not display
and ya my application is in ASP.Net
Title: Not working with Crystal 9   
Name: Lyners
Date: 2005-09-08 9:01:40 AM
Comment:
\
\
\
\
\
\
\
\
Title: Logon failure and incorrect logon parameter errors   
Name: Priya
Date: 2005-09-07 1:30:11 PM
Comment:
Hey guys, those who are using Oracle and connecting the ReportDocument object to Oracle database, and perplexed with that stupid logon error? here is the solution.

1. load the report using ReportDocument.Load() method

2. Use setdatabaselogon on the report doc object and just specify the user name, and password. DOnt use the overload that specifies all four, i.e. user, pasword, database and server. Those who get this error, would be using this overload.

3. dont set any table level logon properties after this.

4. Specify parameter values using the report object report.setparametervalue('parm', val, 'subreportname'); if you are specifying a parameter for your main report, use main report object setparametervalue overload that takes only the parm and the value and not the sub report name

5. Export your report to disk/wherever you want using the export methods. (actually this is where you will get your logon failure errors)

with the above steps, you should be able to get rid of the logon failure error!

Hope this helps (but it still seems wierd to me.. this means that its not possible to runa report using server, database names at runtime.. are crystal reports so difficult to bind to databases at run time?? still digging into this)

-Priya
Title: Crystal Report for Visual Studio .NET   
Name: Ali Gelenler
Date: 2005-09-02 8:13:57 AM
Comment:
You get the error Logon Failed,since your password to access the database doesn't recorded by the Visual Studio for security reasons,so you have to add your password at run time.Just add this code to your Page_Load function, this is in c#;

//first define variables

YourCrystalReport crpt;
CrystalDecisions.Web.CrystalReportViewer CrystalReportViewer;
CrystalDecisions.Shared.TableLogOnInfo myLogin;

//in the page_load

crpt =new YourCrystalReport();

foreach(CrystalDecisions.CrystalReports.Engine.Table myTable in crpt.Database.Tables)
{
myLogin = myTable.LogOnInfo;
myLogin.ConnectionInfo.Password = "yourpassword";
myLogin.ConnectionInfo.UserID = "youruserid";

myTable.ApplyLogOnInfo(myLogin);
}
//now you can assign your report CrystalReportViewer1.ReportSource = crpt;

Hope this will help!

Bye...
Title: Crystal Report   
Name: nell
Date: 2005-08-29 10:41:29 AM
Comment:
this is ok and can help alot, please give or share more examples regarding this topic.

thanks! and godbless.
Title: Crystal Report for Visual Studio .NET   
Name: Juan Carlos Mendoza
Date: 2005-08-24 2:45:57 PM
Comment:
Very good, congratulations.

regards.
Title: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed   
Name: Nirenjan
Date: 2005-08-19 9:42:46 AM
Comment:
I got the same problem but i resolved by removing my previous crystal version dll in the references (Visual studio .Net 2003) and adding new reference with the latest version (i.e removing 9.10 and adding 11.0). This will solve Logon failed issues and invalid report source.
Title: Re: Logon Failure Solution posted by Bob T.   
Name: Arun
Date: 2005-08-09 6:46:42 PM
Comment:
Bob,
SetDatabaseLogon() does not seem to be a supported method for a Crystal Report object in C#. I am using VS .NET 2002 and Crystal Reports for VS .NET. Suggestions?
Thanks, Arun
Title: Error on my program   
Name: Kanagavel
Date: 2005-08-09 1:05:04 AM
Comment:
I am getting the following error. Help me in woring out this proplem. The error comes is like this "CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.
Title: Load report failed   
Name: Jorge Alvarado
Date: 2005-08-03 6:26:23 PM
Comment:
Exception Details: CrystalDecisions.CrystalReports.Engine.LoadSaveReportException: Load report failed.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[LoadSaveReportException: Load report failed.]
CrystalDecisions.Web.ReportAgentBase.m()
CrystalDecisions.Web.ReportAgent.get_RequestContext()
CrystalDecisions.Web.ReportAgent.get_()
CrystalDecisions.Web.ReportAgent.{(Boolean C)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()
Title: Crystal Report   
Name: Prakash
Date: 2005-07-25 3:15:18 AM
Comment:
This article really helped me to work with crystal reports in web application but i dont know how to export the data in to excel.
Title: Cannot find "Data Binding"   
Name: Samuel Tzeng
Date: 2005-07-24 2:38:03 PM
Comment:
Hi Sir,
I cannot find the Data Binding from the Crystal Report Viewer properties. But I am sure my installation was ok without failure. Should I enable what or do anything?

Thanks for everyone's suggestion. jiunshen@gmail.com

Samuel
Title: Good Code   
Name: Krishna
Date: 2005-07-15 1:40:34 AM
Comment:
Sir i am searching for this topic and i got many answers but they didnt solve my problem i like ur way of answering

thankx a lot
Title: An Error occurred during the installation of assembly   
Name: Ethan Yang
Date: 2005-07-12 12:34:54 PM
Comment:
Hi,

I was wondering if anyone could explain the following:

'CrystalDecisions.ReportAppServer.CommonControls.Version = "9.2.3300.0",Culture... HRESULT: 0x80070020.

I get this error message when installing an aplication with the Crystal reports server imbedded on a Citrix environment. The server had crystal 8.5 on their previously and we uninstalled it but we still get this error message.

Any insights would be greatly appreciated! Thanks
Title: Crystal report error logon failed   
Name: Amit Gupta
Date: 2005-07-12 4:15:46 AM
Comment:
Hi There,

I have got one problem when i am using crystal report.that is logon failed .
i don't know why it appears
i have used asp.net/sqlserver

if u have any solution pls mail me at my mail id.
agupta@hanusoftware.com
Title: run project on other server   
Name: narong
Date: 2005-07-07 4:00:51 AM
Comment:
this is ok. but when I copy project to other server. It not install crystal Report and crystal report enterprise. It's cannot run . please advise
Title: i have a question   
Name: caut
Date: 2005-06-28 3:34:51 AM
Comment:
Is it possible to display a vertical object over several sections in Crystal Reports 9?

The object must appear on the right of each page and must have the same orientation regardless of the content of the page.
Title: Crystal Reports 10.0 for .NET   
Name: Basil
Date: 2005-06-22 3:20:45 AM
Comment:
Hello!
Could you help me?
I have a problem with changing push model to pull model.
Sample report have table which is described in field definition file. I want to change connection from TTX file to SQL Server table.

I try to change like this:

rpt.DataSourceConnections[1].SetConnection("MYCOMP","TestDb","sa","");
CrystalDecisions.Shared.TableLogOnInfo tbllogInfo = new CrystalDecisions.Shared.TableLogOnInfo();
CrystalDecisions.Shared.ConnectionInfo cnInfo = new CrystalDecisions.Shared.ConnectionInfo();
tbllogInfo = tbl.LogOnInfo;
cnInfo = tbl.LogOnInfo.ConnectionInfo;
cnInfo.ServerName = "MYCOMP";
cnInfo.DatabaseName = "TestDb";
cnInfo.UserID = "sa";
cnInfo.Password = "";
tbl.LogOnInfo.ConnectionInfo = cnInfo;
tbl.Location = "TestDb.dbo.Table1";
tbl.ApplyLogOnInfo(tbllogInfo);

Then I get LogOnException.


Thank to All.
Title: fail to view report   
Name: shahrizan
Date: 2005-06-20 2:38:04 AM
Comment:
i've followed step by step instruction to view CR report from this site..i've got an error 'Load Report Failed' when i try to run my report.but it's managed to be loaded when i try to bind it during the desing time..

Any advice..
Title: Crystal Report Viewer for VS.Net   
Name: Bhaskar mallela
Date: 2005-06-10 12:54:45 PM
Comment:
Excellent article which give overview of everything about crystal reports on .Net
Title: export html file to doc file   
Name: GiaCatTa
Date: 2005-06-09 5:49:09 AM
Comment:
I want export html file into doc file, but i don't know to how to do it .
you can help me
thanks
Title: Web developer   
Name: Noorah
Date: 2005-06-06 10:22:05 AM
Comment:
Hello
This example worked just fine, But when i use my report insted og the one in the example i reaseve the follwing error:
Logon Failed

Please help to fix this problem.
Regards;
Title: Error Logon failed   
Name: Sudhanshu Lal
Date: 2005-06-04 2:59:52 AM
Comment:
I am getting an error on when i try to preview the report thru the browser i get an error logon failed please someone help as its urgent !!!1
Thnx in advance
Regards
Sudhanshu Lal
Title: Mr robin   
Name: Robin
Date: 2005-05-27 3:48:58 AM
Comment:
this is not working

pull model not working
login failure for the sql server database
pubs db , for integrity secruity or user id

not working...
giving login failure, what is the reason
Title: MR   
Name: robin
Date: 2005-05-27 3:47:58 AM
Comment:
This Pull method is not working

login failure

what is the reason but push method workes
Title: RE: HTML Text Interpretation   
Name: Eric Landes
Date: 2005-05-18 9:43:01 PM
Comment:
I'm not sure what the answer is here. But I would suggest checking out http://www.aspalliance.com/crystal or http://support.businessobjects.com where you might be able to find the answer. HTH
Title: Plug the Crystal report viewer to Enterprise Library Data Access block   
Name: Etienne
Date: 2005-05-18 11:54:29 AM
Comment:
Hi all,

I was stuck cause I wanted to use the mighty Microsoft Enterprise Library to autopopulate a strongly typed dataset that would be the source of my CrystalViewer report...

Thanks to Jason Robinson, I managed to work it out by using:
myDB.LoadDataSet(myCommandWrapper, CType(myTypedDS, DataSet), "DataTableName")

You can also find this info and more at:

Jason's blog:
http://weblogs.asp.net/josh.robinson/archive/2005/03/30/396311.aspx

My blog:
http://etiennel.blogspot.com

Cheers!
Etienne
Title: HTML Text Interpretation   
Name: Arun
Date: 2005-05-18 11:29:32 AM
Comment:
This question was already posted but no responses yet. I would be really thankful if someone can address this

I'm creating crystal reports for a web application, through ASP.NET v1.1. What I noticed was

1) If Crystal Reports 9 is installed HTML Text interpretation option appears in "Format Editor", but
the reports don't show the text in the respective field at all. It shows blank fields.
2) I heard that typing "crHTMLText" in the "Formula Editor window" and clicking on "Save and Close"
does the desired task. So I tried doing that, still it did not work.

Does anyone have any idea of whether this option works in ASP.NET cryastal reports or not? If it doe
sn't work what do I need to do for achieving the effect?
Looking forward to your help....It is urgent!!

Thx in advance.
Title: Solution of CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed   
Name: Shedrek
Date: 2005-05-14 6:18:36 AM
Comment:
This exception occurs when u r not logon to the database...
in vb.net we use setDatabaseLogon(uid,pwd) method.....
e.g
crReportDocument.SetDatabaseLogon("sa", "sa")
Title: Solution to dataset problem   
Name: Eric Landes
Date: 2005-05-11 11:54:10 PM
Comment:
Thanks for sharing your solution on this Ken.
Title: One solution to the "The 'multiple tables in dataset' camp "   
Name: Ken
Date: 2005-05-11 4:26:59 PM
Comment:
On a hunch, I created a view with selects an a few joined tables. I then call the view in a stored procedure.

Next, I open up Visual Studio .NET (2003) and create a new dataset. The Server Explorer contains the newly created view. I drag and drop the view into the design area and save.

Next, I create the report. In the details section I Database/Add/Remove Database... and include the dataset I created. The names of the fields are there as would any table. Drag and drop the fields according to this articles directions.

Later, in the .aspx report viewer code, I create the mechanism for calling the stored procedure. When I fill my custom dataset via the data adapter, I refer to it as 'myAdpt.Fill(myDataSet, "myView");', just as one would fill the custom dataset given in this article's example. It works.

Have fun.
Title: The 'multiple tables in dataset' camp   
Name: Ken
Date: 2005-05-11 3:20:02 PM
Comment:
There were a few inquiries about using multiple tables within the dataset. I would like to know how that is done as well. I was able to use the 'push' model example effectively, filling the dataset with a stored procedure, etc. However, I cannot achieve output using a dataset with multiple tables. Tracing through the code, I can set that the dataset has the proper results from the stored procedure I'm using, but the data never reaches the report fields.
Title: Logon Failure Solution   
Name: Bob T
Date: 2005-05-06 1:41:10 PM
Comment:
Below is a working solution to the logon failure first posted by Srinivas Bandi:

add the following code in page load event instead of databind logon failed error should go away.

Dim crreport As New pulltest 'replace pulltest by your reportname
crreport.SetDatabaseLogon("username", "password") 'replace username and password
CrystalReportViewer1.ReportSource = crreport

It really can't be put much cleaer for those of you using VB.

In C# use the following:

protected INSERTREPORTNAMEHERE rep = new INSERTREPORTNAMEHERE(); //(My report is named INSERTREPORTNAMEHERE.rpt)

private void Page_Load(object sender, System.EventArgs e)
{
mf.SetDatabaseLogon("username","password");
CrystalReportViewer1.ReportSource = rep;
CrystalReportViewer1.DataBind();
}
Title: Could not create instance of the report   
Name: sups
Date: 2005-05-03 7:33:12 AM
Comment:
I made a simple report CrystalReport1.rpt which was added to my project (Add New Item => Crystal Rep
ort).
I want to use the report in my project:
CrystalReport1 = new CrystalReport1();
But I get this compile-error:
The type or namespace name 'CrystalReport1' could not be found (are you missing a using directive or
an assembly reference?)
The report is in another folder called Reports in the root folder. I am not getting this report, where as if i create a report in the root directory i get it.
What is wrong?
Title: crystal report convert in pdf in asp.net   
Name: amit
Date: 2005-05-03 2:26:53 AM
Comment:
hi tech
how i design a crystal report in asp.net ,now my problem is how to crystal report convert in pdf in asp.net on button click
help us
send sample code
thankx
Title: RE: runtime error   
Name: Eric Landes
Date: 2005-04-27 10:31:32 PM
Comment:
Since I don't see any code or an error message, it's pretty hard to help out. I would suggest going to http://support.businessobjects.com for help, or http://aspalliance.com/crystal and look on the community page for some of the different mailing lists that can help.
Title: runtime error   
Name: jason
Date: 2005-04-27 4:23:45 PM
Comment:
i used the above example in one of my applications, i used the pull method with the world sales report.rpt file, the report is rendered in the design view but when i build and try opening the page in a browser, it gives me a runtime error...can someone help me here?
Title: RE Change VB to C#   
Name: Eric Landes
Date: 2005-04-20 10:04:56 PM
Comment:
To change that code, I think you'll just need to add a ; to the end of each line. Here's a link to a project that converts VB.net to C# http://www.codeproject.com/csharp/GBVB.asp HTH
Title: change vb code to c#   
Name: ttu
Date: 2005-04-20 8:54:53 AM
Comment:
i want to convert this code to c# but i don't know how can i
?
please help me.
CrystalReportViewer1.LogOnInfo.Item(0).ConnectionInfo.UserID = user
CrystalReportViewer1.LogOnInfo.Item(0).ConnectionInfo.Password = pass
CrystalReportViewer1.LogOnInfo.Item(0).ConnectionInfo.ServerName = server
CrystalReportViewer1.LogOnInfo.Item(0).ConnectionInfo.DatabaseName =dbname
CrystalReportViewer1.DataBind()
Title: Logon Error   
Name: Mark Lewis
Date: 2005-04-19 7:10:11 AM
Comment:
I was having loads of problems with the logon error. The code i used to get round it was:

Dim rpt As New CrystalReport
rpt.SetDatabaseLogon("user", "password")
CrystalReportViewer.ReportSource = rpt
CrystalReportViewer.DataBind()

Note I am only using the username and password and NOT the database and server options as well.
Title: Logon failed error   
Name: Upendra Chaudhari
Date: 2005-04-19 6:56:02 AM
Comment:
Hi
I'm trying a simple example but using an ODBC connection to a Sybase database. Th
e connection is working fine when building the report, but when I call the DataBind() method I'm get
ting a Login Failed message. What am I missing?


Exception Details: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

Stack Trace:
[LogOnException: Logon failed.]
.F(String  , EngineExceptionErrorID 
)
.A(Int16 , Int32 )
.@(Int16 )
CrystalDecisions.CrystalReports.Engine.FormatEngine.GetPage(PageRequestContext reqContext)
CrystalDecisions.ReportSource.LocalReportSourceBase.GetPage(PageRequestContext pageReqContext)
CrystalDecisions.Web.ReportAgent.u(Boolean N)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()
Title: logon failed error sloved by   
Name: Srinivas Bandi
Date: 2005-04-13 3:59:50 PM
Comment:
add the following code in page load event instead of databind logon failed error should go away.

Dim crreport As New pulltest 'replace pulltest by your reportname
crreport.SetDatabaseLogon("username", "password") 'replace username and password
CrystalReportViewer1.ReportSource = crreport
Title: crystal report in asp.net   
Name: subhashchandra
Date: 2005-04-12 6:45:05 AM
Comment:
hy,
i am a student of b.e.computer engg. i am working on asp.net.
1) i want to know how to make crystal report in asp.net
2) how to convert rpt file to pdf file format.
3) how pdf file send to selected email-id.

please send me reply early.

my email id- sardhara_subhash@yahoo.com
Title: Login error   
Name: D
Date: 2005-03-30 2:10:48 PM
Comment:
Mansur,Prasad,Joe,Mihir,Michael,Rob,...
This error can be anything from a Bad Parameter Data Type to typo in the source path or even report name or maybe something else I am not aware of. I will watch first for a typo. Happen to me this morning :-O
Title: Crystal Reports with selected data records   
Name: Sachin
Date: 2005-03-30 5:39:06 AM
Comment:
Thank You very much for your detailed explanation,but if we want to retrive particular records of a database table then what sould we do?Please answer as early as possible.

With Regards,
Sachin
Title: Crystal Report   
Name: Sachin
Date: 2005-03-30 5:34:06 AM
Comment:
Really helpful.Thanks for your detailed explanation.
With Regards,
Sachin B.
Title: LogOnException: Logon failed   
Name: Prasad
Date: 2005-03-30 1:37:09 AM
Comment:
I'm not able to get the solution for this. If anybody can plz.


[LogOnException: Logon failed.]
.F(String  , EngineExceptionErrorID 
)
.A(Int16 , Int32 )
.@(Int16 )
CrystalDecisions.CrystalReports.Engine.FormatEngine.GetPage(PageRequestContext reqContext)
CrystalDecisions.ReportSource.LocalReportSourceBase.GetPage(PageRequestContext pageReqContext)
CrystalDecisions.Web.ReportAgent.u(Boolean N)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()
Title: Crystal Reports   
Name: Sreedhar
Date: 2005-03-29 10:29:35 AM
Comment:
How to create crystal report dynamically in asp.net
Title: Good article but still lacks one thing.   
Name: Preeti Sharma
Date: 2005-03-22 1:31:45 PM
Comment:
Hi,
No doubt this article is more than enough. Its very good.
One which has written it is making concept very clear.
But still one thing is left. As i am looking for a code to create report using dataset. In this example dataset is crated using wizard. I m making query at rum time and generating dataset at run time. But in that case i m unable to generate report. Is it possible for author of this article to hepl me in this matter.
Thanks a lot.
Preeti Sharma
Title: Logon failed. SQL Server Solution   
Name: Alex K.S.Lim
Date: 2005-03-22 2:45:06 AM
Comment:
http://support.microsoft.com/default.aspx?scid=kb;en;319264&sd=msdn

This Articles explained why, and Solution in C# Code.
I changed the code to VB.Net code and it worked.
Title: Push model displays an empty report   
Name: Janki
Date: 2005-03-21 6:19:54 PM
Comment:
I used the same source code as given above, to connect to a database using SQL Server authentication. Though it no longer throws logon failed exception, it displays an empty report.
Please HELP !
Title: re: logon failed solution   
Name: gurvin
Date: 2005-03-21 2:17:34 PM
Comment:
i got the same error "CrystalDecisions.CrystalReports.Engine.LogOnException: Logon Failed"
and I removed the password for my SQL Server, uid=sa pwd=
this is a temporary solution, I will dig in more to find out why this exception occuring.
Title: Field Explorer   
Name: Mahe
Date: 2005-03-13 8:32:52 PM
Comment:
go to View/Other Windows/Document Outline. This should bring your field explorere.
Title: Comma expected   
Name: Joe
Date: 2005-03-13 4:24:20 AM
Comment:
BC30196: Comma expected

I have even put the crystal report to the same directory. this error still comes up. Can anyone help? Thanks in advance!
Title: can't find Field Explorer   
Name: mahe
Date: 2005-03-12 6:53:32 AM
Comment:
After the table being selected on step 10)(Expand the "Pubs" database, expand the "Tables", select t
he "Stores" table and click on ">" to include it into the "Selected Tables" section), the Field Expl
orer didn't show up on my screen. Does any one has any idea what is going on on my set up? Many than
k!
Title: thanks   
Name: srinivas
Date: 2005-03-11 10:09:16 AM
Comment:
hi
the code is working all for pop method but geting an error when using push and tring to export it to doc file as
logon failed
pls help me
thanks
srinivas
mail id srinivaspeesapati@yahoo.co.in
Title: Crystal Report for Visual Studio .NET   
Name: Ngoc suong
Date: 2005-02-26 10:51:11 PM
Comment:
thanks for explanation, but when you want to use more tables how does it work ?
bye
Title: Field Explorer didn't show up   
Name: Kening Wang
Date: 2005-02-23 12:16:19 PM
Comment:
After the table being selected on step 10)(Expand the "Pubs" database, expand the "Tables", select the "Stores" table and click on ">" to include it into the "Selected Tables" section), the Field Explorer didn't show up on my screen. Does any one has any idea what is going on on my set up? Many thank!
Title: CrystalReport1 = new CrystalReport1();   
Name: Marinus
Date: 2005-02-23 9:22:49 AM
Comment:
I made a simple report CrystalReport1.rpt which was added to my project (Add New Item => Crystal Report).
Now I want to use this report in my project:
CrystalReport1 = new CrystalReport1();
But I get this compile-error:
The type or namespace name 'CrystalReport1' could not be found (are you missing a using directive or an assembly reference?)
What is wrong?
Title: Connection string   
Name: chow
Date: 2005-02-22 2:13:02 AM
Comment:
The connection string in Bindreport() is giving me error. I am not able to connect to the SQL2K. FYI, I did not set any password for 'sa'. Do I need to change the connectcion string ? Any idea ?
Title: Logon failed with ODBC connection   
Name: Germano
Date: 2005-02-19 3:06:17 PM
Comment:
I'm trying a simple example like the one above but using an ODBC connection to a Sybase database. The connection is working fine when building the report, but when I call the DataBind() method I'm getting a Login Failed message. What am I missing?
Title: Alignment of Data   
Name: Liying
Date: 2005-02-19 11:50:45 AM
Comment:
Can someone help me?

I am trying to create a table of content that is horizontal. How can i go about doing it? Each time the report get generated it will tabulate different number of columns. I have been trying for 1 week but failed to make the report auto create columns of data.

Is it possible to add HTML code to Formula Editor??
if it is possible. how can i go about doin it?

Thank you in advance.
Title: Learn Crystal Reports in 21 Minutes   
Name: Malik Asif joyia
Date: 2005-02-16 1:32:42 AM
Comment:
Hello
Very good Effort by Ajay and Shanker. i am realy very thankfull to them for this kind of good guideness to the people who are learning Cyrstal Reports.
Thanks Again
Title: Logon failed   
Name: Confused
Date: 2005-02-14 4:48:00 PM
Comment:
Did anyone figure out how to get passed that LogOnException:Logon Failed Error? I tried changing permissions in the folder to store file but still get the error.
Title: Crystal Report for Asp.net   
Name: Laxmi
Date: 2005-02-11 5:04:45 AM
Comment:
I got to view the report at design time but in run time i could see only the control...can someone h
elp me with that?
thanks
Title: Crystal Reports for ASP.NET   
Name: Dhana
Date: 2005-02-07 10:07:24 PM
Comment:
I am using the same steps as described above.
But in the runtime it always shows -

Exception Details: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


Stack Trace:
[LogOnException: Logon failed.]
.F(String  , EngineExceptionErrorID 
)
.A(Int16 , Int32 )
.@(Int16 )
CrystalDecisions.CrystalReports.Engine.FormatEngine.GetPage(PageRequestContext reqContext)
CrystalDecisions.ReportSource.LocalReportSourceBase.GetPage(PageRequestContext pageReqContext)
CrystalDecisions.Web.ReportAgent.u(Boolean N)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()
Title: Export in 2 lines!   
Name: Andrew Denman
Date: 2005-02-04 10:47:09 PM
Comment:
\
\
Title: crystal report   
Name: haytham
Date: 2005-01-26 9:59:33 AM
Comment:
very good article but it is not as we required in our project.:(
Title: Crystal Reports Walkthrough - Using the Pull Model   
Name: senthilkumar
Date: 2005-01-21 5:46:39 AM
Comment:
Code Behind Page Modifications

18) Call the Databind method on the Page Load Event of the Code Behind file (.aspx.vb).

in the databind method what we have to do,please show me the code in databind
Title: Problem while using the PULL model   
Name: Aresung
Date: 2005-01-18 10:48:49 PM
Comment:
Followed the steps to create a new report using the Pull Model. And able to view the preview of the report with dummy data.

But while running the application, getting an error.

CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.
Title: One solution to the Logon Fail problem   
Name: Angel Huerta
Date: 2005-01-12 5:47:25 PM
Comment:
Check out this KB:

http://support.microsoft.com/default.aspx?scid=kb;en;319264&sd=msdn
Title: Crystal Report for Visual Studio .NET   
Name: Rob Morgan
Date: 2005-01-05 2:20:14 PM
Comment:
\
\
\
Title: Mr.   
Name: Bill Anklemoore
Date: 2005-01-04 2:36:20 AM
Comment:
How about the "passing user input parameters" model. This is far more useful than the "push" or "pull" model. Simply put, Crystal Reports can't do this online!
Title: Thanks a lot !   
Name: Vijay
Date: 2004-12-29 1:34:28 AM
Comment:
I got exactly what I was looking for. Very useful article on Crystal Reports in .NET. Thanks.
Title: Crystal Report for Visual Studio .NET   
Name: Richard Dudley
Date: 2004-12-24 1:20:55 AM
Comment:
>DiskOpts.DiskFileName = "c:\Output.pdf"
Title: logon failed   
Name: Michael Zhao
Date: 2004-12-20 11:30:17 PM
Comment:
I got a logon failed error as well

-----------------
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[LogOnException: Logon failed.]
.F(String  , EngineExceptionErrorID 
)
.A(Int16 , Int32 )
.@(Int16 )
CrystalDecisions.CrystalReports.Engine.FormatEngine.GetPage(PageRequestContext reqContext)
CrystalDecisions.ReportSource.LocalReportSourceBase.GetPage(PageRequestContext pageReqContext)
CrystalDecisions.Web.ReportAgent.u(Boolean N)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()
Title: Crystal report connection with oracle   
Name: marcelo
Date: 2004-12-20 11:54:01 AM
Comment:
i have this error when i connect with oracle 8i or 9i at then runing time. Anybody have then solution.

Thank

Error is "CrystalDecisions.CrystalReports.Engine.LogOnException: Logon Failed"
Title: Not working in runttime   
Name: Visu
Date: 2004-12-09 2:44:33 AM
Comment:
In design time CrystalReport viewer able to display information But in runtime i am not able to get.
I am getting login failed ..
Title: Crystal Report for Visual Studio .NET   
Name: Richard Dudley
Date: 2004-11-18 8:45:54 PM
Comment:
\
Title: Background image   
Name: Butch Pornebo
Date: 2004-10-22 9:56:32 PM
Comment:
How do you set the background image of the page in Crystal Report?
Title: Crystal Report for Visual Studio .NET   
Name: dhanya
Date: 2004-10-13 5:37:13 AM
Comment:
i got to view the report at design time but in run time i could see only the control...can someone help me with that?
thanks
Title: Logon error   
Name: Mike
Date: 2004-10-11 1:23:00 PM
Comment:
I got that logon error on an export, it was because of rights on the folder. Took me hours to find that.
Title: HTML Text Interpretation   
Name: Himani
Date: 2004-10-06 8:40:26 AM
Comment:
I'm creating crystal reports for a web application, through ASP.NET v1.1. What I noticed was
1) If Crystal Reports 9 is not installed on machine, the option of HTML text interpretation does not appear in "Format Editor" of the reports that are being created through .NET.
2) If Crystal Reports 9 is installed HTML Text interpretation option appears in "Format Editor", but the reports don't show the text in the respective field at all. It shows blank fields.
3) I heard that typing "crHTMLText" in the "Formula Editor window" and clicking on "Save and Close" does the desired task. So I tried doing that, still it did not work.

Does anyone have any idea of whether this option works in ASP.NET cryastal reports or not? If it doesn't work what do I need to do for achieving the effect?
Looking forward to your help....It is urgent!!

Thx in advance.
Title: LogOnException: Logon failed   
Name: Mihir Aich
Date: 2004-10-06 8:31:12 AM
Comment:
I am using the same steps as described above.
But in the runtime it always shows -

Exception Details: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

Stack Trace:
[LogOnException: Logon failed.]
.F(String  , EngineExceptionErrorID 
)
.A(Int16 , Int32 )
.@(Int16 )
CrystalDecisions.CrystalReports.Engine.FormatEngine.GetPage(PageRequestContext reqContext)
CrystalDecisions.ReportSource.LocalReportSourceBase.GetPage(PageRequestContext pageReqContext)
CrystalDecisions.Web.ReportAgent.u(Boolean N)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()
Title: Crystal Reports with Oracle   
Name: SEE#YEM
Date: 2004-09-22 10:43:54 AM
Comment:
Guys,
I googled and banged with supports but could not solve the issue with Crystal Reports not able to connect to Oracle and i get a same default error message which is not allowing me to pass the gate at all..Any help would be apperciated...

Error is "CrystalDecisions.CrystalReports.Engine.LogOnException: Logon Failed"
Title: Challenging doubt   
Name: Naushad
Date: 2004-09-09 7:43:30 AM
Comment:
HI,
can i use some other datasource other than datasets in push model?..my requirement is to display data in a crystal report as when they are read from a file.Note the data is not stored in a database.
Title: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.   
Name: Vinodh
Date: 2004-09-06 5:42:57 AM
Comment:
Thanx,like the above examples, i have done using oracle but i got error saying that CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.
any suggestion on that.
Title: Exception of type System.Exception was thrown.   
Name: Mansur A
Date: 2004-08-18 10:03:37 AM
Comment:
I tried the code.On compiling it the following error occurs.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[Exception: Exception of type System.Exception was thrown.]
CrystalDecisions.Web.ReportAgent.u(Boolean N)
CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Control.PreRenderRecursiveInternal()
System.Web.UI.Page.ProcessRequestMain()



Im have tried many tricks but to no avail !!
Hope you can answer back !
Mansur
Title: CS1009: Unrecognized escape sequence   
Name: sam
Date: 2004-07-31 2:10:28 PM
Comment:
hi
I can see the report in the design mode.
but when i run it i get the following error.
CS1009: Unrecognized escape sequence
Do we have to escape the reportpath while binding it to the reportsource
pl help
thanks.
Title: crystal reports   
Name: alen
Date: 2004-07-27 7:19:26 AM
Comment:
this is ok, but when we r runing the same in oracle with ado.net .
the report is not generating the required rows as executed by the query given in the connection string,
instead it is showing all rows in report
what is the solution for this
Title: use more tables   
Name: eli
Date: 2004-06-23 2:24:56 AM
Comment:
thanks for explanation, but when you want to use more tables how does it work ?
bye
Title: Crystal Report for Visual Studio .NET   
Name: Richard Dudley
Date: 2004-06-19 11:23:40 PM
Comment:
\

Product Spotlight
Product Spotlight 



Community Advice: ASP | SQL | XML | Regular Expressions | Windows


©Copyright 1998-2018 ASPAlliance.com  |  Page Processed at 2018-09-22 1:21:29 AM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search