Solved

ReportSmith

Posted on 1997-05-12
3
268 Views
Last Modified: 2010-04-06
I would like to create temporary files with Delphi that can then be used by ReportSmith.  How do I change the table that ReportSmith uses at runtime.  I have used the Delphi connection, however that only allows one table or query from Delphi.  Is there some way I can substitute the file that ReportSmith uses at runtime with a temporary file that is built by Delphi?

Thanks
Ian Hopewell
Hopewell and Associates
e-mail: ianah@iaccess.za
0
Comment
Question by:Ianah
[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
3 Comments
 
LVL 3

Accepted Solution

by:
hpierson earned 50 total points
ID: 1336182
Ian,

Being simple minded and the king of kludges, I would probably rename the original table to keepsafe.db, rename the temporary table to originaltable.db, run the report, rename the temporary table back to its old name, then rename keepsafe.db back to its original name..

Fortunately, the TTable componet does have a renametable method, so all this skulldugery will only take four lines of code...and since it all happens in Delphi, you can leave your report alone and avoid learning the macro language in Reportsmith!

Harry M. Pierson
DREJ Consulting
0
 

Author Comment

by:Ianah
ID: 1336183
I would like multiple users on the network to print this report.  If I rename my files there will be a clash with what other users are doing.  This report will be in a multi user environment. Any suggestion?
0
 
LVL 3

Expert Comment

by:hpierson
ID: 1336184
Suppose the table to be replace is

F:\somedirectory\realtable.db

copy the table to

c:\temp\realtable.db

Load the original report, and replace the table
F:\somedirectory\realtable.db with the table
c:\temp\realtable.db

in the reportsmith report, and save it under a different name, say
NEWREPRT.RPT

Now your users don't have to rename anything, the just have to copy or rename the table they want to use in any report to

c:\temp\realtable.db,

and since these tables will be local to each user, all common tables retain their original names and locations, and will be untouched.

I hope this is clear.

Harry M. Pierson
DREJ Consulting


0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

717 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