Skip to Content
author's profile photo Former Member
Former Member

PrintToPrinter function hangs when deployed with the CR XI R2 merge modules

I am using CR for VS .NET and the reports are designed in CR XI R2 version. From my VS development environment, I am able to use the PrintToPrinter function from C# code and able to print to the server's default printer. However, when I build the application and deploy it with the merge modules (that came with CR XI R2), the PrintToPrinter function never returns and hangs for ever. There are no exceptions being thrown. The account running the web application has admin privileges to network printers, shares etc. but it still does not work. The code to print is setup as follows:

ReportDocument objDoc=new ReportDocument();

// Load the report





// Print the report

objDoc.PrintToPrinter(1, true, 0, 0); <-- this hangs for ever

If I just view the report then that works ok; it is the direct printing that hangs. Any ideas?

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Dec 23, 2008 at 04:50 PM

    Hi Faisal,

    It seems that you are having issue with Crystal reports .Net SDK's.

    Post your question in Crystal Reports .NET SDK forum.

    That forum is monitored by qualified technicians and you will get a faster response there. Also, all .NET SDK queries remain in one place and thus can be easily searched in one place.

    With more info:

    What is the version of visual studio you are using?

    Have you applied any service pack for crystal reports?

    Are you printing a single report are more reports together?

    Is the issue is with all the report?



    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.