CodeGuru Forums -
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic Newsletters VB Forums Developer.com


Newest CodeGuru.com Articles:

  • Installing SQL Server 2008
  • Writing UDFs for Firebird Embedded SQL Server
  • [Updated] Shutdown Manager
  • Building Windows Azure Cloud Service Applications with Azure Storage and the Azure SDK

  • Search CodeGuru:
     



    Go Back   CodeGuru Forums > Visual Basic Programming > Crystal Reports
    FAQ Members List Calendar Search Today's Posts Mark Forums Read

    Reply
     
    Thread Tools Search this Thread Rate Thread Display Modes
      #1    
    Old March 16th, 2004, 09:23 AM
    chadi chadi is offline
    Junior Member
     
    Join Date: Mar 2004
    Posts: 3
    chadi is an unknown quantity at this point (<10)
    send output to printer - crystal report 8.5

    Hi,

    I am trying to send the output of a crystal report straight to the printer without viewing the report. I have already created the report using visual basic 6.0 and I can view the report.

    I just need to print it without viewing it. How can I do that ?
    I tried "viewer.printreport", but did not work.

    Thanks.
    Reply With Quote
      #2    
    Old March 16th, 2004, 03:25 PM
    James Longstreet James Longstreet is offline
    Member
     
    Join Date: Apr 1999
    Location: VA BEACH
    Posts: 467
    James Longstreet is an unknown quantity at this point (<10)
    use the report obejct and the PrintOut method.
    Reply With Quote
      #3    
    Old March 16th, 2004, 03:50 PM
    chadi chadi is offline
    Junior Member
     
    Join Date: Mar 2004
    Posts: 3
    chadi is an unknown quantity at this point (<10)
    Hi James,

    I am actually using the report object, but when I use the printout method to print the report the print dialog box pops up. How can I get rid of it and make it seemless to the user ?

    Please advice

    Thanks.
    Reply With Quote
      #4    
    Old March 17th, 2004, 08:33 AM
    chadi chadi is offline
    Junior Member
     
    Join Date: Mar 2004
    Posts: 3
    chadi is an unknown quantity at this point (<10)
    How to get rid of the print dialog box

    Hi,

    I am using the report object and the Report.printout method to send a report straight ot the printer without viewing it.

    The problem is the print dialog box that keeps poping up every time. How can I get rid of it ?


    Thanks.
    Reply With Quote
      #5    
    Old June 21st, 2005, 04:08 AM
    chetansalgaonkar chetansalgaonkar is offline
    Junior Member
     
    Join Date: Jun 2005
    Posts: 1
    chetansalgaonkar is an unknown quantity at this point (<10)
    Question Re: send output to printer - crystal report 8.5

    hi,

    i am new to this group. I am facing the same problem... i want the output to be printed directly on a print click and also print dialogue box should not pop up...

    did you get any solution for this... then pls reply back...
    Reply With Quote
      #6    
    Old June 21st, 2005, 08:08 AM
    rahulvasanth rahulvasanth is offline
    Member
     
    Join Date: Sep 2004
    Posts: 265
    rahulvasanth is on a distinguished road (10+)
    Re: send output to printer - crystal report 8.5

    HI

    before giving "viewer1.Printreport" you also have to specify "Viewer1.Viewreport" , only then will the report be printed directly to the printer.
    Reply With Quote
      #7    
    Old October 25th, 2005, 07:41 AM
    khizerharoon khizerharoon is offline
    Junior Member
     
    Join Date: Oct 2005
    Posts: 1
    khizerharoon is an unknown quantity at this point (<10)
    Smile Re: send output to printer - crystal report 8.5

    You can use

    Report.PrintOut False 'printer report without prompt

    and it would work
    Reply With Quote
      #8    
    Old August 30th, 2008, 01:02 AM
    im_haroon2003 im_haroon2003 is offline
    Junior Member
     
    Join Date: Aug 2008
    Posts: 1
    im_haroon2003 is an unknown quantity at this point (<10)
    Re: send output to printer - crystal report 8.5

    Hi,

    I am facing a problem regarding "Report.PrintOut" method.

    After the sub containing " Report.PrintOut false" finish executing, the application closes.
    Can anyone tell me what could be the problem??

    I am using Crystal Report 9.0 & VB6.

    Thanks
    Reply With Quote
      #9    
    Old September 4th, 2008, 04:09 AM
    CrystalBabysteps CrystalBabysteps is offline
    Member
     
    Join Date: Feb 2007
    Posts: 32
    CrystalBabysteps is an unknown quantity at this point (<10)
    Re: send output to printer - crystal report 8.5

    Quote:
    After the sub containing " Report.PrintOut false" finish executing,the application closes
    appears to be some coding problem. check if you have some lines like End or routine to exit the application, after executing the sub to view/print report
    __________________
    Reporting Tool: CR9
    Reply With Quote
      #10    
    Old December 8th, 2008, 10:28 AM
    thecaptainjs thecaptainjs is offline
    Member
     
    Join Date: Jul 2002
    Posts: 44
    thecaptainjs is an unknown quantity at this point (<10)
    Re: send output to printer - crystal report 8.5

    I am having an issue trying to do this.

    I guess I am not understanding what the report object is.
    I currently use the Crystal Reports Object, but there is no PrintOut function to use, so I must be misunderstanding something.
    Reply With Quote
      #11    
    Old December 8th, 2008, 10:46 AM
    jggtz jggtz is offline
    Member +
     
    Join Date: Jul 2005
    Posts: 551
    jggtz has a spectacular aura about (125+)jggtz has a spectacular aura about (125+)
    Re: send output to printer - crystal report 8.5

    There are several ways to activate the Crystal Reports 8.5 engine in a VB6 application
    OCX, RDC & CRAPI
    The PrintOut is a method from the report object when we use RDC
    In order to use it,

    1.- You must set a reference to a Crystal Reports ActiveX Designer RunTime Library 8.5 in Your VB6 project

    2.- Declare
    Code:
    Dim  CRApp        As New CRAXDRT.Application
    Dim  CRReport     As New CRAXDRT.Report
    3.-Assign & Print
    Code:
    Set CRReport = CRApp.OpenReport(App.Path & "\MyReport.rpt", 1)
    CRReport.PrintOut False
    4.-Don't forget to clear resources
    Code:
    Set CRReport = Nothing
    Set CRApp = Nothing

    Last edited by jggtz; December 8th, 2008 at 10:53 AM.
    Reply With Quote
    Reply

    Bookmarks
    Go Back   CodeGuru Forums > Visual Basic Programming > Crystal Reports


    Thread Tools Search this Thread
    Search this Thread:

    Advanced Search
    Display Modes Rate This Thread
    Rate This Thread:

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off
    Forum Jump


    All times are GMT -5. The time now is 08:51 AM.



    Acceptable Use Policy

    internet.comMediabistrojusttechjobs.comGraphics.com

    WebMediaBrands Corporate Info


    Advertise | Newsletters | Feedback | Submit News

    Legal Notices | Licensing | Permissions | Privacy Policy


    Powered by vBulletin® Version 3.7.3
    Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
    Copyright WebMediaBrands Inc. 2002-2009