Solved

How to call Crystal Reports

Posted on 1998-08-24
3
229 Views
Last Modified: 2010-08-05
i just want to know how to call a crystal reports. For example i want to call it from a visual basic program with SQL statement.

What i want to do is to pass the data i have selected from my visual basic program to Crystal reports and direct it to printer.

pls help me on this.

thanks in advance,

spritep
0
Comment
Question by:spritep
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 2

Expert Comment

by:vspeter
ID: 1430831
I don't think that you can pass your data directly to crystal report. However have your query as stored procedure and in designing your report, select the stored procedure as your input.

0
 

Accepted Solution

by:
entretec earned 100 total points
ID: 1430832
Seagate now have a FREE Report Designer that send send any datasource directly to a report, etc. It covers DAO, ADO, SQL. The Report Designer runs in the VB5 IDE. Download from www.img.seagatesoftware
0
 

Expert Comment

by:rutexavier
ID: 1430833
First you must add the control to your vb program, so had the crystal Report.ocx control and place it on the from. then supose you give it the name REPORT.
then place a command button in the form and in it place the code:

Report.ReportFileName = "c:\report_file_name.rpt" 'you report file name and path
Report.WindowTitle = "My Report"

'here you must place the formula. between quotes you must put the database table name (socios) and then a point (.) and the field to search (n_socio)
Report.SelectionFormula = "{socios.n_socio} =" & value_to_find
Report.Action = 1

0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
VBA Shell can't Find Word document 11 155
VB6 - Convert HH:MM into Decimal 8 75
Advice in Xamarin 21 119
Excel 2007 Random Generate List Based on Defined Source Cells 3 29
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

737 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question