Results 1 to 9 of 9

Thread: Crystal Report & VB Printing

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Sep 2000
    Posts
    20

    Question

    I have a combo box that contain a list of installed printers. However this only have the printer names. I also need the following info for crystal reports:

    CurrentPrintDriver = Printer.DriverName
    CurrentPrintName = Printer.DeviceName
    CurrentPrintPort = Printer.Port

    CrystalReport1.PrinterDriver = CurrentPrintDriver
    rystalReport1.PrinterName = CurrentPrintName
    CrystalReport1.PrinterPort = CurrentPrintPort

    Can anyone please help me with this???


    Thanks.

  2. #2
    Member
    Join Date
    May 2000
    Location
    Canada
    Posts
    52
    intPrinter = 1
    For Each oPrn In Printers
    strPrinterDriver(intPrinter) = oPrn.DriverName
    strPrinterPort(intPrinter) = oPrn.Port
    cboInvoicePrinter.AddItem oPrn.DeviceName
    intPrinter = intPrinter + 1
    Next

    You can write these values to arrays while you are populating the combo box.

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Sep 2000
    Posts
    20

    Talking

    d.paulson

    THANK YOU!!! This works great!!!

  4. #4
    Lively Member
    Join Date
    Jul 2000
    Location
    Brunei
    Posts
    100
    Originally posted by mikegt
    I have a combo box that contain a list of installed printers. However this only have the printer names. I also need the following info for crystal reports:

    CurrentPrintDriver = Printer.DriverName
    CurrentPrintName = Printer.DeviceName
    CurrentPrintPort = Printer.Port

    CrystalReport1.PrinterDriver = CurrentPrintDriver
    rystalReport1.PrinterName = CurrentPrintName
    CrystalReport1.PrinterPort = CurrentPrintPort

    Can anyone please help me with this???


    Thanks.
    Hi there,

    Hope you can help me. I am a beginner, trying to use Crystal reports. In my VB6 program, when the user clicks a command button, the crystal report has to opened.

    How can I do this? Your help would be greatly appreciated.

    Thank you.

    Rathi.J

  5. #5

    Thread Starter
    Junior Member
    Join Date
    Sep 2000
    Posts
    20
    Hope this helps. Also somewhat beginner with cr.

    'Use 0 here for preview or a 1 to print with no preview
    CrystalReport1.Destination = 0

    'Tell cr the report file you want to use.
    CrystalReport1.ReportFileName = "c:\MyReport.rpt"

    'Process request.
    CrystalReport1.Action = 1

  6. #6
    Addicted Member
    Join Date
    Aug 2000
    Location
    Fremont Ohio 43420
    Posts
    253
    Hello mikegt

    I was wondering if you know much about charting in Crystal Reports? I have a problem with my chart.

    Thanks jeffro.

  7. #7

    Thread Starter
    Junior Member
    Join Date
    Sep 2000
    Posts
    20
    Sorry Jeffro, I don't know much about charing.. Maybe someone else here can help you with that one.

  8. #8
    Addicted Member
    Join Date
    Aug 2000
    Location
    Fremont Ohio 43420
    Posts
    253

    Talking

    Thanks anyway!

  9. #9
    Lively Member
    Join Date
    Jul 2000
    Location
    Brunei
    Posts
    100
    Originally posted by mikegt
    Hope this helps. Also somewhat beginner with cr.

    'Use 0 here for preview or a 1 to print with no preview
    CrystalReport1.Destination = 0

    'Tell cr the report file you want to use.
    CrystalReport1.ReportFileName = "c:\MyReport.rpt"

    'Process request.
    CrystalReport1.Action = 1

    Thanks for your help and time.

    Could you pls.be more specific about
    CrystalReport1.ReportFileName property.

    What are the declarations I have to make at the beginning?

    Any help would be greatly appreciated.

    Thanks again.

    sincerely,
    Rathi.j


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