Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Crystal Reports Change Location of Database
Message
 
To
18/02/2002 18:47:35
John Mcdonald
Mcdonald Consulting Group
Fort Myers, Florida, United States
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00621721
Message ID:
00621929
Views:
6
>I'm trying to use the OCX for Crystal Reports through Foxpro and I can get it to run with the stored data in the report. I am trying to change the location of the report to point at another spot. It doesn't change the report.
>
>The report is a simple list, the database is exactly the same but I am changing it to look at another directory.
>
>crystalapplication = CreateObject("Crystal.CRPE.Application")
>crystalReport = crystalApplication.OpenReport("C:\PFSAR\LOGIN.RPT")
>
>**The Following line I change the source from c:\pfsar to o:\pfsar
>crystalReport.Database.Tables.item(1).location="o:\pfsar\login.dbf"
>**
>
>crystalReport.ExportOptions.FormatType = 3
>crystalReport.ExportOptions.DiskFileName = "c:\pfsar\test.txt"
>crystalReport.ExportOptions.DestinationType = 1
>crystalReport.Export(.t.)
>
>Thanks in advance.
>
>Any ideas?

Try:

CrystalReport.Database.Tables(1).SetTableLocation("o:\pfsar","o:\pfsar", "")
-Paul

RCS Solutions, Inc.
Blog
Twitter
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform