?
Solved

Delphi program fails to print on only some computers/printers

Posted on 2005-05-15
6
Medium Priority
?
272 Views
Last Modified: 2010-04-05
Program written with Delphi 3 on WinXP OS fails to print on only certain computers. A test program using DOS printing as well as varying printer codes in Delphi merely ejects a blank page when attempting to print on such printers. No problem printing from origiinal machine that was used to write the programs. Difficult to test this because it malfunctions on distant machines.
0
Comment
Question by:DeCordova
  • 2
4 Comments
 
LVL 6

Expert Comment

by:vadim_ti
ID: 14006710
what report generator component  you use?
0
 

Author Comment

by:DeCordova
ID: 14015399
Using TPrintDialog. It appears to be the only one available on my version of Delphi 3.
0
 
LVL 2

Accepted Solution

by:
prevarant earned 2000 total points
ID: 14216220
Hi

The best and easiest way:

put "printers" in uses list then

example>

procedure TForm1.FormCreate(Sender: TObject);
combobox1.items:=printer.items; // get lst of ALL INSTALLED printers
begin
end;

procedure TForm1.ComboBox1Change(Sender: TObject);
begin
  printer.PrinterIndex:=combobox1.ItemIndex //setting printer
end;

procedure TForm1.Button1Click(Sender: TObject);
begin
form1.print// or whatever You want to print
end;
0
 

Author Comment

by:DeCordova
ID: 14286836
That appears to do the same thing as PrintDialog1.Execute which only picks a printer. No problem with that. I am having some success by programming pixels to be equivalent regardless of which printer is used.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

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

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Integration Management Part 2
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
Suggested Courses

850 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