roioep
asked on
Changing default printer for IReport
Hi,
I have a project in Delphi 4 using Crystal Report IReport.
The printer of the IReport is the Windows default printer but I want to be able to select any printer.
Please provide code !
I have a project in Delphi 4 using Crystal Report IReport.
The printer of the IReport is the Windows default printer but I want to be able to select any printer.
Please provide code !
Your printer selection for the running app is storeed in the printer index. All you need to do is drop TPrintDialog, then fire it with
printdialog1.execute;
User changes to the selection in the dialog will effect your application for as long as it is running, and accross forms. As long as your reports are not hardcoded to a printer and are instead using the default, you should be fine.
printdialog1.execute;
User changes to the selection in the dialog will effect your application for as long as it is running, and accross forms. As long as your reports are not hardcoded to a printer and are instead using the default, you should be fine.
ASKER
I want to print directly from Delphi without any dialogs.
ASKER
I want to print directly from Delphi without any dialogs.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
This question has been classified abandoned. I will make a recommendation to the moderators on its resolution in a week or two. I appreciate any comments that would help me to make a recommendation.
Unless it is clear to me that the question has been answered I will recommend delete. It is possible that a Grade less than A will be given if no expert makes a case for an A grade. It is assumed that any participant not responding to this request is no longer interested in its final disposition.
If the user does not know how to close the question, the options are here:
https://www.experts-exchange.com/help/closing.jsp
mnye
EE Cleanup Volunteer
Unless it is clear to me that the question has been answered I will recommend delete. It is possible that a Grade less than A will be given if no expert makes a case for an A grade. It is assumed that any participant not responding to this request is no longer interested in its final disposition.
If the user does not know how to close the question, the options are here:
https://www.experts-exchange.com/help/closing.jsp
mnye
EE Cleanup Volunteer
Not sure.
mlmcc
mlmcc
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
PAQ/No Refund, resolved by YodaMage
Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
mnye
EE Cleanup Volunteer
I will leave a recommendation in the Cleanup topic area that this question is:
PAQ/No Refund, resolved by YodaMage
Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
mnye
EE Cleanup Volunteer
If you preview the report first you should be able to change the printer when you print from the preview screen.
Does the following solve your problem?
http://support.crystaldecisions.com/library/kbase/articles/c2003743.asp
In VB there is a property on the CR control which can be set
CR_Object.PrinterName = MyPrinter
Delphi I am sure has something similar.
mlmcc