Trouble printing reports in color

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bhughes2187
    New Member
    • Mar 2008
    • 32

    Trouble printing reports in color

    Ok people here have been an extremely great help.

    I have a problem once again.. It was working fine but now is broke again.

    I have a routine that loops through my reports and sends them to a printer or PDFCreator. Wierd thing is, my first report that has color on it, keeps coming out black and white.. Every other report that has color prints with its color.. I am so confused.

    Here is the snippet of code that runs through the execution of the reports.

    Code:
    'If option is print to PDF set default printer to PDFCreator and start PDFCreator
      Set Application.Printer = Application.Printers("PDFCreator") 'Call to print to PDF Creator
        
     'start PDFCreator
      Set pdfjob = New clsPDFCreator
      If pdfjob.cStart("/NoProcessingAtStartup") = False Then
       Shell "taskkill /IM /T PDFCreator.exe", vbHide
      End If
       With pdfjob
         .cPrinterStop = True
         .cOption("UseAutoSave") = 1
         .cOption("UseAutoSaveDirectory") = 1
         .cOption("AutoSaveDirectory") = pdfpath
         .cOption("AutoSaveFilename") = pdfname
         .cOption("AutoSaveFormat") = 0    '0 = PDF
         .cClearCache
       
       'Determine if need to print out cover sheet and Table of Contents
       If rt.RecordCount > 1 Then
        DoCmd.OpenReport "mailto", acViewNormal
        DoCmd.OpenReport "rpt1", acViewNormal
        Sleep (1000)
       End If
       
       'Print out the reports in the batch
       For pgA = 0 To rt.RecordCount - 1
        ' Set Application.Printer = Application.Printers("PDFCreator") 'Call to set printer to PDFCreator
        RPT = "rpt" & Rprt(0, pgA)
        DoCmd.OpenReport RPT, acViewNormal
        Sleep (1000)
       Next pgA
  • bhughes2187
    New Member
    • Mar 2008
    • 32

    #2
    Ok, so I cannot go back and amply name my post..


    I have to make note that it is not only while printing to PDF that this happens. If I am printing to a color printer it happens too..

    I have made sure that the printers default settings are set to color. I have even trid using
    Code:
    with application.printers("pdfcreator")
     .ColorMode = acPRCMColor
    end with
    I just don't get it.

    Comment

    • NeoPa
      Recognized Expert Moderator MVP
      • Oct 2006
      • 32656

      #3
      Originally posted by bhughes2187
      Ok, so I cannot go back and amply name my post.
      ...
      If by this you mean you would like to rename your thread then please feel free to post here (or PM me if you prefer) with a new name and I will arrange to do it for you (assuming the new title matches the guidelines of course).

      PS. I'm sorry, but I can't help much with your actual problem.

      Comment

      • missinglinq
        Recognized Expert Specialist
        • Nov 2006
        • 3533

        #4
        I already re-titled the thread, Ade!

        ;0)>

        Comment

        • Stewart Ross
          Recognized Expert Moderator Specialist
          • Feb 2008
          • 2545

          #5
          Hi. I use PDFCreator routinely to route printed output from Access, Excel and Word to PDF, though not via automation (just using it as a normal printer). I find that in some cases it is not consistent about colour processing, for example of charts pasted into Word reports from Excel, which show in colour on Word's print preview but print in monochrome on the PDFCreator. Access reports have been faithfully reproduced, although as I have said I am not using automation to generate them.

          I mention this because I suspect that there is nothing at all wrong with your code, and that you may simply have to live with some inconsistencies in output to PDFCreator, inconsistencies which might not be there if you were using the Adobe Acrobat Distiller, say, to capture to PDF. Trouble is, PDFCreator is one of the few PDF drivers that is possible to automate under program control (as far as I know Adobe don't provide such support for Distiller, although I believe it is possible). PDFCreator is also open source, unlike Distiller which is costly...

          -Stewart

          Comment

          • NeoPa
            Recognized Expert Moderator MVP
            • Oct 2006
            • 32656

            #6
            Originally posted by missinglinq
            I already re-titled the thread, Ade!
            NOW it makes more sense. I jumped in expecting to have to change it but all I found was the reference quoted to wanting a change.

            I link from a bunch at once so I'm allowed to get confused easily ;D

            Comment

            • missinglinq
              Recognized Expert Specialist
              • Nov 2006
              • 3533

              #7
              We always allow for your advancing years, Ade!

              Linq ;0)>

              P.S. Actually, I've got shoes older than you are, Ade, and they're not even broken in yet!

              Comment

              Working...