Solved

Crystal Reports from within VB 5

Posted on 1998-07-21
5
200 Views
Last Modified: 2010-05-03
I am printing a Crystal Report from within VB. I only have one report to print so I am using the "easy" method of adding the Crystal Reports component and then simply attaching a code to a command button to execute the report. I have it set to pop up in a window by default.  The report needs to be printed on two sides. When I created the report I set it that way, and if I print from Crystal Reports program it does print two sided, however it does not from within VB. Can someone please help. I would be happy to even just have a normal print dialog box that would pop up to allow me to change it to two sided. Thank you
0
Comment
Question by:webguru
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 

Author Comment

by:webguru
ID: 1466333
Adjusted points to 200
0
 
LVL 4

Accepted Solution

by:
trkcorp earned 200 total points
ID: 1466334
So, have just that... The crystal report control has a printerselect method that presents a printer dialog:

CrystalReport1.PrinterSelect

This imposes an "override" for the run of the report without permanently setting printer attributes and allows the user access to select a printer and set its properties.

Another option is to just use the common dialog control:

CommonDialog1.ShowPrinter

which is a system change of printer but still allows the user to select a printer and set its properties.
0
 

Author Comment

by:webguru
ID: 1466335
I do not believe my Crystal Reports 4.6 supports crystalreports.PrinterSelect however the commondialog component worked fine. Thank You for your help
0
 
LVL 4

Expert Comment

by:trkcorp
ID: 1466336
Great, glad to be of service.
0
 

Author Comment

by:webguru
ID: 1466337
Hey trkcorp, could you read my other question? And see if you can help. I have worked on this problem for a while now to no avail.
If you can thanks, if not its ok,

jeff
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses
Course of the Month8 days, 20 hours left to enroll

617 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question