Results 1 to 4 of 4

Thread: CR9 export to PDF

  1. #1

    Thread Starter
    Hyperactive Member VB4fun's Avatar
    Join Date
    May 2003
    Location
    too far from Fiji
    Posts
    342

    CR9 export to PDF

    I have tried and tried to work through a printer issue (see thread CR9...easier????) And now CRDecisions is telling me to export to PDF and try that issue.

    Has anyone done this successfully, without hours and hours of frustration?

    I am distributing an app with acrobat reader already a part of it, Using VB6 and CR9.

    I am wondering what kind of advice anyone can give on exporting exsisting .rpt files to PDF format, so the end users can print (no matter what the printer is) and have a success.

    Ideas?

  2. #2
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758
    I read the other post but sorry I can offer no help.

    I don't have CR9, the following code to export to pdf was written for version 8.5.

    VB Code:
    1. Dim objApp As CRAXDRT.Application
    2.     Dim objReport As CRAXDRT.Report
    3.     Dim objExportOptions As CRAXDRT.ExportOptions
    4.     Dim objTable As CRAXDRT.DatabaseTable
    5.    
    6.     Set objApp = New CRAXDRT.Application
    7.    
    8.     Set objReport = objApp.OpenReport("d:\testing\report1.rpt")
    9.    
    10.     With objReport
    11.         For Each objTable In .Database.Tables
    12.             'set the login information for SQL server or Oracle.
    13.             objTable.SetLogOnInfo  ...
    14.         Next
    15.    
    16.         Set objExportOptions = .ExportOptions
    17.  
    18.         With objExportOptions
    19.             .DestinationType = crEDTDiskFile
    20.             .DiskFileName = "D:\Testing\Report.pdf"
    21.             .FormatType = crEFTPortableDocFormat
    22.             .PDFExportAllPages = True
    23.         End With
    24.        
    25.         .ReadRecords
    26.         .DisplayProgressDialog = False
    27.         .Export False
    28.    
    29.     End With
    30.    
    31.     Set objTable = Nothing
    32.     Set objExportOptions = Nothing
    33.     Set objReport = Nothing
    34.     Set objApp = Nothing

  3. #3

    Thread Starter
    Hyperactive Member VB4fun's Avatar
    Join Date
    May 2003
    Location
    too far from Fiji
    Posts
    342
    Thanks for your reply,

    Dont suppose you have some advice on the DLL's...?

    I havent made it far enough to deploy the app with the export part..but from what I am reading...the DLL's are frustrating if you dont know exactly which ones and have no control over the registration..

    I am using VB6, CR9...and will be having people load my app at other locations, thus manually registering is not an option for this situation...

    Any help or advice would be greatly appreciated.

  4. #4
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758
    the DLL's are frustrating if you dont know exactly which ones and have no control over the registration..
    You are right, people seem to have problems installing the run-time files for Crystal.

    Fortunately, I have never experienced these issues. The information you need is in the RunTime.hlp file. It tells you exactly which files need to be installed. Just take the time and care to investigate which dependancy dlls are required, especially if your app is going to be installed on multiple OS.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width