Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

REPORTSMITH HELP!!!

Posted on 1997-04-30
2
Medium Priority
?
731 Views
Last Modified: 2006-11-17
For my program in Delphi I need to make about 50 reports. I think it's best to make them in ReportSmith 3.0. Though I can not work with it. How can I use reports in my Delphi program and can I give variables to my report.
Example: Report for all students with a group the user can choose
Database : Name Groep Lastname Result
             Tom Fr04  De Decker  5
             Stijn Fr03 De Decker 4
            Jens  Fr04  De Decker 5
            Gordian Fr04 Vermarien 2
I need to make a report of all students who are in group Fr04 and have at least 5 and of all students who are in group Fr03. The groups should be variabels to the report
1 report for all groups. is this possible? Can I give variables from my delphi program to my report??
HOW??? Please Help Me It's urgent!!!!!!!!!!!!!
You'll get good points
:) Thanx to anybody wwho wants to help me with a FULL explanation.
0
Comment
Question by:DDTom23
[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
  • 2
2 Comments
 
LVL 2

Accepted Solution

by:
javiertb earned 360 total points
ID: 1335787
First of all I should tell you that it's much more easier
using TQuery instead of ReportSmith, but anyway, here you go:
- In order to get that report you first access ReportSmith and
 select the table you want from the Tables section.
- Then you go to Report Variables tab and define your two
 variables which would be Group1 (to chose the first group
 you want the students result to be greater or equal than 5)
 and Group2 (for the students who are in Fr03 in your example).
- Now you go to Selections and set the selection criteria, that
in your case, it would look something like this:

 . Include records in the report where 'any' of the following    aply
   1. 'all' of the following aply
     1.1. 'datafield' 'table1.Group' 'is equal to' 'report            variable' 'Var1'
     1.2. 'datafield' 'table1.Result' 'is greater than or equal            to' 'number' 5
   2. 'datafield' 'table1.Group' 'is equal to' 'report variable'       'Var2'

- Once you have all this set, you save the report and then access ReportSmith component property InitialValues, where you can set by code the variables you want to pass.
i.e.
Report1.InitialValues.Add('Var1=<'+YourSelectedGroup1+'>');
Report1.InitialValues.Add('Var2=<'+YourSelectedGroup2+'>');
Report1.Run;

Hope this helps
0
 
LVL 2

Expert Comment

by:javiertb
ID: 1335788
Hey, there! Could you evaluate my answer, please?
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

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

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
Suggested Courses

662 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