Print Page | Close Window

myReport.PrintToPrinter generating two copies

Printed From: Crystal Reports Book
Category: Crystal Reports for Visual Studio 2005 and Newer
Forum Name: Writing Code
Forum Discription: .NET programming API, report integration
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=8781
Printed Date: 05 May 2025 at 8:13am


Topic: myReport.PrintToPrinter generating two copies
Posted By: newbie14
Subject: myReport.PrintToPrinter generating two copies
Date Posted: 03 Jan 2010 at 8:52am

Dear All,
            I have been using this method myReport.PrintToPrinter(1, false, 0, 0);  to print to the printer all the while working well for all my other print out. But now I have use this for another my receipt printing it is always printing two copies. To add on I have even put like this myReport.PrintToPrinter(0, false, 0, 0);  but yet it prints two copies. Any solution to this? Thank you in advance.




Replies:
Posted By: hilfy
Date Posted: 04 Jan 2010 at 7:35am
Are there two copies when you view the report in Crystal before you print?  If so, then this is a data issue.  Try turning on "Select Distinct" in the Database menu.  If that doesn't work, you may have to do something with your groups so that it only displays once.
 
-Dell


-------------
Proviti, Data & Analytics Practice
http://www.protiviti.com/US-en/data-management-advanced-analytics - www.protiviti.com/US-en/data-management-advanced-analytics


Posted By: newbie14
Date Posted: 04 Jan 2010 at 7:43am
Dear Dell,
               No there is no duplicate data in my crystal report viewer it is just one page only. So what I have done now is that move the same code to another page and it works fine no more two copies. So what can possible the problem ya ?



Print Page | Close Window