Click to See Complete Forum and Search --> : Changing table name at run time in crystal rep. through VB


Manish Kale
January 27th, 1999, 05:24 AM
I want to change the table at run time. I will explain u the situation.

I have a database operating in the multiuser environment. User keeps on consolidating the reports at the end of the year (or they may do it in the mid'ts also).

They r stored in a table with the name and the year eg. Consolidation 1998, Consolidation 1999 etc.

My problem is if I want a single rpt file to generate all the report based on the different Consolidation tables.

I am using Vb 5.0 to generate reports.

I hope I have given u a clear picture. any doubt please ask me.

See if u can answer me at the earliest.

Thanks in adv.

Wolfgang Kutschera
February 8th, 1999, 06:31 AM
Easy way: (There should be a better one too, but I donīt know crystal good enough so I use this one)

Don't base the report on a table, use a view! (Query in Access) At runtime just drop the view and create it pointing to the table you currently need and then call the report.

Voila!


brgds

Wolfgang "Rick" Kutschera

Scientific Games Austria

Systemprogramming

Moor
June 3rd, 1999, 05:03 AM
In a multi user environment (generally), all the users willl not have rights to drop, create objects dynamically. Then what may be the solution?