SlideShare ist ein Scribd-Unternehmen logo
1 von 26
Crystal Report
• What is crystal report?

• How to implement using crystal report
What is crystal report
• Crystal Reports is a business intelligence application used to
  design and generate reports from a wide range of data
  sources.
• Crystal Reports is the built-in report designing tool in Visual
  Studio .NET and it is fully integrated with windows and web
  applications.
How data transferred
• Imagine we are using ADO .NET to get a subset of data from
  SQL Server and store it in a DataSet. Then we conduct the
  data from dataset to CrystalReportViewer object to be
  displayed.
• SQL Server -> SQLConnection -> SQLDataAdaptor -> DataSet -
  > CrystalReportDocument -> CrystalReportViewer -> ASP .NET
  web page.
• In .NET application Crystal Report Document reads the data
  from dataset, NOT directly from data provider and this is the
  key point to Crystal Report integration with .NET.
Crystal Report Advantages
• major advantage of using crystal report for
  visual studio .NET are
  *Rapid report development
  *can extend it to complicated reports with
  interactive charts
  *can programmatically export the reports into
  widely used formats like
  .pdf,.doc,.xls,.html,and .rtf
Publish Content Into Crystal Report
• ***There are 2 ways to publish content into Crystal
  1. Pull Method
  2. Push Method

* Crystal Reports, like many other applications, connects to a
  database by way of a database driver, where each driver is
  designed to handle a specific database type or method of data
  access. With Crystal Reports, you can use one of two models
  of accessing data: "Pull" and "Push."
Pull Model
• In this model, the report will connect to the database, using
   the parameters given to it a design time, to pull the data as
   needed.
• In this mode, all of the work is done by the report:
 * connecting to the database and issuing the SQL commands;
 *These are all handled without any coding from the developer.
 *This is the default model of Crystal Reports.
Push Method
• The push model involves code written by a developer that:
 * creates and calls a connection on the database,
 *executes the SQL commands,
 *creates a record set or dataset that matches the fields in the
  report, and then assigns the object to the report.



This model also allows the shaping and filtering of data before it
  reaches the report.
Steps to create a crystal report
• Create a new website and right click on solution explorer >
  add new Item > Select Crystal Report
  In the dialog box choose blank report.
• Now click on CrystalReports Menu in VS and select DataBase
  Expert
• In database expert dialog box expend create new connection
  > OLEDB(ADO) section
• Now select Microsoft OLE DB provider for sql server
• Connection information
• Selected data base you choose was selected
• In next screen Expend your database objects in left pane and
  add the tables you want to use in right pane
• Then after next step view the field explore shown like this
• Now design the report , drag and fields from Database fields
  in field explorer and which you want to show in report and
  drop them in Section3(Details), and preview the report, it
  should look like show below.
• Report preview look like this
Create a aspx page
• <form id="form1" runat="server">
  <div>
 <CR:CrystalReportViewer ID="CrystalReportViewer1"
  runat="server" AutoDataBind="True" Height="1039px"
  ReportSourceID="CrystalReportSource1" Width="901px" />
 <CR:CrystalReportSource ID="CrystalReportSource1"
  runat="server">
 <Report FileName="CrystalReport.rpt"> </Report>
  </CR:CrystalReportSource>
 </div>
 </form>
Code Behind
• Protected Sub Page_Load (ByVal sender As Object, ByVal e As
  EventArgs)
  Dim crystalReport As New ReportDocument()
  crystalReport.Load(Server.MapPath("CrystalReport.rpt"))
  crystalReport.SetDatabaseLogon ("amit", "password",
  "AMITSQLEXPRESS", "TestDB")
  CrystalReportViewer1.ReportSource = crystalReport End Sub
Thank you
Disclaimer: This presentation is prepared by trainees of baabtra as a part of
mentoring program. This is not official document of baabtra – Mentoring Partner
baabtra – Mentoring Partner is the mentoring division of baabte System Technologies Pvt. Ltd
Contact Us

Weitere ähnliche Inhalte

Was ist angesagt? (20)

Object oriented databases
Object oriented databasesObject oriented databases
Object oriented databases
 
Event handling
Event handlingEvent handling
Event handling
 
ASP.NET- database connectivity
ASP.NET- database connectivityASP.NET- database connectivity
ASP.NET- database connectivity
 
JavaScript - Chapter 12 - Document Object Model
  JavaScript - Chapter 12 - Document Object Model  JavaScript - Chapter 12 - Document Object Model
JavaScript - Chapter 12 - Document Object Model
 
Jsp ppt
Jsp pptJsp ppt
Jsp ppt
 
Ado.Net Tutorial
Ado.Net TutorialAdo.Net Tutorial
Ado.Net Tutorial
 
JSON: The Basics
JSON: The BasicsJSON: The Basics
JSON: The Basics
 
javascript objects
javascript objectsjavascript objects
javascript objects
 
Transaction states and properties
Transaction states and propertiesTransaction states and properties
Transaction states and properties
 
Distributed database
Distributed databaseDistributed database
Distributed database
 
Bootstrap
BootstrapBootstrap
Bootstrap
 
Java Servlets
Java ServletsJava Servlets
Java Servlets
 
Mvc architecture
Mvc architectureMvc architecture
Mvc architecture
 
Asp .net web form fundamentals
Asp .net web form fundamentalsAsp .net web form fundamentals
Asp .net web form fundamentals
 
Ordbms
OrdbmsOrdbms
Ordbms
 
SQL - Structured query language introduction
SQL - Structured query language introductionSQL - Structured query language introduction
SQL - Structured query language introduction
 
Relational algebra ppt
Relational algebra pptRelational algebra ppt
Relational algebra ppt
 
ADO.NET
ADO.NETADO.NET
ADO.NET
 
SQLite database in android
SQLite database in androidSQLite database in android
SQLite database in android
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
 

Ähnlich wie Crystal report

crystalReport.pptx
crystalReport.pptxcrystalReport.pptx
crystalReport.pptxsamreen82
 
Crystal Reports Review
Crystal Reports ReviewCrystal Reports Review
Crystal Reports ReviewJustin R. Rue
 
MSBI-SQL Server Reporting Services
MSBI-SQL Server Reporting ServicesMSBI-SQL Server Reporting Services
MSBI-SQL Server Reporting ServicesThejaswi shasthri
 
Business Intelligence Technology Presentation
Business Intelligence Technology PresentationBusiness Intelligence Technology Presentation
Business Intelligence Technology PresentationJohn Paredes
 
SQL to NoSQL: Top 6 Questions
SQL to NoSQL: Top 6 QuestionsSQL to NoSQL: Top 6 Questions
SQL to NoSQL: Top 6 QuestionsMike Broberg
 
Deliver Dynamic and Interactive Web Content in J2EE Applications
Deliver Dynamic and Interactive Web Content in J2EE ApplicationsDeliver Dynamic and Interactive Web Content in J2EE Applications
Deliver Dynamic and Interactive Web Content in J2EE Applicationsinfopapers
 
Pnbhfl training final
Pnbhfl training finalPnbhfl training final
Pnbhfl training finalNupur Mishra
 
Hitchhiker’s Guide to SharePoint BI
Hitchhiker’s Guide to SharePoint BIHitchhiker’s Guide to SharePoint BI
Hitchhiker’s Guide to SharePoint BIAndrew Brust
 
Balamurugan msbi cv
Balamurugan msbi cvBalamurugan msbi cv
Balamurugan msbi cvbala murugan
 
Azure Data Factory V2; The Data Flows
Azure Data Factory V2; The Data FlowsAzure Data Factory V2; The Data Flows
Azure Data Factory V2; The Data FlowsThomas Sykes
 
SQL Server Reporting Services
SQL Server Reporting ServicesSQL Server Reporting Services
SQL Server Reporting ServicesAhmed Elbaz
 
Vb.net session 16
Vb.net session 16Vb.net session 16
Vb.net session 16Niit Care
 
how to move data from on premise to ssis in google cloud platform ,azure, sno...
how to move data from on premise to ssis in google cloud platform ,azure, sno...how to move data from on premise to ssis in google cloud platform ,azure, sno...
how to move data from on premise to ssis in google cloud platform ,azure, sno...KeerthuBabu
 

Ähnlich wie Crystal report (20)

crystal report
crystal reportcrystal report
crystal report
 
Rdlc (1)
Rdlc (1)Rdlc (1)
Rdlc (1)
 
crystalReport.pptx
crystalReport.pptxcrystalReport.pptx
crystalReport.pptx
 
Crystal Reports Review
Crystal Reports ReviewCrystal Reports Review
Crystal Reports Review
 
MSBI-SQL Server Reporting Services
MSBI-SQL Server Reporting ServicesMSBI-SQL Server Reporting Services
MSBI-SQL Server Reporting Services
 
Business Intelligence Technology Presentation
Business Intelligence Technology PresentationBusiness Intelligence Technology Presentation
Business Intelligence Technology Presentation
 
SQL to NoSQL: Top 6 Questions
SQL to NoSQL: Top 6 QuestionsSQL to NoSQL: Top 6 Questions
SQL to NoSQL: Top 6 Questions
 
Deliver Dynamic and Interactive Web Content in J2EE Applications
Deliver Dynamic and Interactive Web Content in J2EE ApplicationsDeliver Dynamic and Interactive Web Content in J2EE Applications
Deliver Dynamic and Interactive Web Content in J2EE Applications
 
Pnbhfl training final
Pnbhfl training finalPnbhfl training final
Pnbhfl training final
 
Ssrs 2008 R2 webinar
Ssrs 2008 R2   webinarSsrs 2008 R2   webinar
Ssrs 2008 R2 webinar
 
It ready dw_day4_rev00
It ready dw_day4_rev00It ready dw_day4_rev00
It ready dw_day4_rev00
 
Hitchhiker’s Guide to SharePoint BI
Hitchhiker’s Guide to SharePoint BIHitchhiker’s Guide to SharePoint BI
Hitchhiker’s Guide to SharePoint BI
 
SAP Business Objects Trianing
SAP Business Objects TrianingSAP Business Objects Trianing
SAP Business Objects Trianing
 
Balamurugan msbi cv
Balamurugan msbi cvBalamurugan msbi cv
Balamurugan msbi cv
 
Azure Data Factory V2; The Data Flows
Azure Data Factory V2; The Data FlowsAzure Data Factory V2; The Data Flows
Azure Data Factory V2; The Data Flows
 
AhmedWasfi2015
AhmedWasfi2015AhmedWasfi2015
AhmedWasfi2015
 
SQL Server Reporting Services
SQL Server Reporting ServicesSQL Server Reporting Services
SQL Server Reporting Services
 
Vb.net session 16
Vb.net session 16Vb.net session 16
Vb.net session 16
 
Ssrs tutorial
Ssrs tutorialSsrs tutorial
Ssrs tutorial
 
how to move data from on premise to ssis in google cloud platform ,azure, sno...
how to move data from on premise to ssis in google cloud platform ,azure, sno...how to move data from on premise to ssis in google cloud platform ,azure, sno...
how to move data from on premise to ssis in google cloud platform ,azure, sno...
 

Mehr von baabtra.com - No. 1 supplier of quality freshers

Mehr von baabtra.com - No. 1 supplier of quality freshers (20)

Agile methodology and scrum development
Agile methodology and scrum developmentAgile methodology and scrum development
Agile methodology and scrum development
 
Best coding practices
Best coding practicesBest coding practices
Best coding practices
 
Core java - baabtra
Core java - baabtraCore java - baabtra
Core java - baabtra
 
Acquiring new skills what you should know
Acquiring new skills   what you should knowAcquiring new skills   what you should know
Acquiring new skills what you should know
 
Baabtra.com programming at school
Baabtra.com programming at schoolBaabtra.com programming at school
Baabtra.com programming at school
 
99LMS for Enterprises - LMS that you will love
99LMS for Enterprises - LMS that you will love 99LMS for Enterprises - LMS that you will love
99LMS for Enterprises - LMS that you will love
 
Php sessions & cookies
Php sessions & cookiesPhp sessions & cookies
Php sessions & cookies
 
Php database connectivity
Php database connectivityPhp database connectivity
Php database connectivity
 
Chapter 6 database normalisation
Chapter 6  database normalisationChapter 6  database normalisation
Chapter 6 database normalisation
 
Chapter 5 transactions and dcl statements
Chapter 5  transactions and dcl statementsChapter 5  transactions and dcl statements
Chapter 5 transactions and dcl statements
 
Chapter 4 functions, views, indexing
Chapter 4  functions, views, indexingChapter 4  functions, views, indexing
Chapter 4 functions, views, indexing
 
Chapter 3 stored procedures
Chapter 3 stored proceduresChapter 3 stored procedures
Chapter 3 stored procedures
 
Chapter 2 grouping,scalar and aggergate functions,joins inner join,outer join
Chapter 2  grouping,scalar and aggergate functions,joins   inner join,outer joinChapter 2  grouping,scalar and aggergate functions,joins   inner join,outer join
Chapter 2 grouping,scalar and aggergate functions,joins inner join,outer join
 
Chapter 1 introduction to sql server
Chapter 1 introduction to sql serverChapter 1 introduction to sql server
Chapter 1 introduction to sql server
 
Chapter 1 introduction to sql server
Chapter 1 introduction to sql serverChapter 1 introduction to sql server
Chapter 1 introduction to sql server
 
Microsoft holo lens
Microsoft holo lensMicrosoft holo lens
Microsoft holo lens
 
Blue brain
Blue brainBlue brain
Blue brain
 
5g
5g5g
5g
 
Aptitude skills baabtra
Aptitude skills baabtraAptitude skills baabtra
Aptitude skills baabtra
 
Gd baabtra
Gd baabtraGd baabtra
Gd baabtra
 

Crystal report

  • 1.
  • 3. • What is crystal report? • How to implement using crystal report
  • 4. What is crystal report • Crystal Reports is a business intelligence application used to design and generate reports from a wide range of data sources. • Crystal Reports is the built-in report designing tool in Visual Studio .NET and it is fully integrated with windows and web applications.
  • 5. How data transferred • Imagine we are using ADO .NET to get a subset of data from SQL Server and store it in a DataSet. Then we conduct the data from dataset to CrystalReportViewer object to be displayed. • SQL Server -> SQLConnection -> SQLDataAdaptor -> DataSet - > CrystalReportDocument -> CrystalReportViewer -> ASP .NET web page. • In .NET application Crystal Report Document reads the data from dataset, NOT directly from data provider and this is the key point to Crystal Report integration with .NET.
  • 6. Crystal Report Advantages • major advantage of using crystal report for visual studio .NET are *Rapid report development *can extend it to complicated reports with interactive charts *can programmatically export the reports into widely used formats like .pdf,.doc,.xls,.html,and .rtf
  • 7. Publish Content Into Crystal Report • ***There are 2 ways to publish content into Crystal 1. Pull Method 2. Push Method * Crystal Reports, like many other applications, connects to a database by way of a database driver, where each driver is designed to handle a specific database type or method of data access. With Crystal Reports, you can use one of two models of accessing data: "Pull" and "Push."
  • 8. Pull Model • In this model, the report will connect to the database, using the parameters given to it a design time, to pull the data as needed. • In this mode, all of the work is done by the report: * connecting to the database and issuing the SQL commands; *These are all handled without any coding from the developer. *This is the default model of Crystal Reports.
  • 9. Push Method • The push model involves code written by a developer that: * creates and calls a connection on the database, *executes the SQL commands, *creates a record set or dataset that matches the fields in the report, and then assigns the object to the report. This model also allows the shaping and filtering of data before it reaches the report.
  • 10. Steps to create a crystal report
  • 11. • Create a new website and right click on solution explorer > add new Item > Select Crystal Report In the dialog box choose blank report.
  • 12. • Now click on CrystalReports Menu in VS and select DataBase Expert
  • 13. • In database expert dialog box expend create new connection > OLEDB(ADO) section
  • 14. • Now select Microsoft OLE DB provider for sql server
  • 16. • Selected data base you choose was selected
  • 17. • In next screen Expend your database objects in left pane and add the tables you want to use in right pane
  • 18. • Then after next step view the field explore shown like this
  • 19. • Now design the report , drag and fields from Database fields in field explorer and which you want to show in report and drop them in Section3(Details), and preview the report, it should look like show below.
  • 20. • Report preview look like this
  • 21.
  • 22. Create a aspx page • <form id="form1" runat="server"> <div> <CR:CrystalReportViewer ID="CrystalReportViewer1" runat="server" AutoDataBind="True" Height="1039px" ReportSourceID="CrystalReportSource1" Width="901px" /> <CR:CrystalReportSource ID="CrystalReportSource1" runat="server"> <Report FileName="CrystalReport.rpt"> </Report> </CR:CrystalReportSource> </div> </form>
  • 23. Code Behind • Protected Sub Page_Load (ByVal sender As Object, ByVal e As EventArgs) Dim crystalReport As New ReportDocument() crystalReport.Load(Server.MapPath("CrystalReport.rpt")) crystalReport.SetDatabaseLogon ("amit", "password", "AMITSQLEXPRESS", "TestDB") CrystalReportViewer1.ReportSource = crystalReport End Sub
  • 25. Disclaimer: This presentation is prepared by trainees of baabtra as a part of mentoring program. This is not official document of baabtra – Mentoring Partner baabtra – Mentoring Partner is the mentoring division of baabte System Technologies Pvt. Ltd