Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Frustrated by Crystal Reports Automation Server
Message
De
27/09/1999 11:40:40
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
27/09/1999 11:00:00
Ken Zinssar
Newkirk Products Inc
Albany, New York, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00269361
Message ID:
00269405
Vues:
22
>The following code works perfectly to refresh the data & preview my report, in Vbasic...
>
>Dim CrystalApplication As CRPEAuto.Application
>Dim CrystalReport As CRPEAuto.Report
>Dim DbName As CRPEAuto.Database
>Dim DbTables As CRPEAuto.DatabaseTables
>Dim DbTable As CRPEAuto.DatabaseTable
>
>Private Sub Form_Load()
>Set CrystalApplication = CreateObject("Crystal.CRPE.Application")
>Set CrystalReport = CrystalApplication.OpenReport("C:\Program Files\Seagate Software\Crystal Reports\A.rpt")
>
>Private Sub CmdPrintReport_Click()
>Call CrystalReport.DiscardSavedData
>Call CrystalReport.Database.Verify
>CrystalReport.Preview
>End Sub
>
>!!!THE EQUIVALENT FOX CODE listed below DOES NOT!!! WHY!??!
>
>LCrwApp=Createobject('Crystal.CRPE.Application')
>LCrwRep=LCrwApp.OpenReport("C:\Program Files\Seagate Software\Crystal Reports\A.rpt")
>LCrwRep.DiscardSavedData
>LcrwRep.Database.verify
>LcrwRep.Preview
>
>ARE WHY WE GOING TO ADMIT TO ANY SUPERIORITY IN VB?!!!


Ken,
That code runs perfectly on my system (of course .rpt name is different). Are you using ODBC ? If so might that be the problem ? What I do is to create report with some data, then at runtime SQL select into a cursor, copy to ... type fox2x, change Crytal.report.tables.location and preview. Works well.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform