Solved

I'm using Richedit.print but it will not print across a network

Posted on 2002-07-23
12
172 Views
Last Modified: 2010-04-04
I'm using the richedit.print because it word wraps during printing.  This feature works great to a local printer. But when I use the print dialog to select the printers, it list all of the printers on the network. I select the network printer and nothing happens, I wait for the Windows 2000 print window it never comes up.  I get no errors and nothing prints.

I need help.

Thanks Jim
0
Comment
Question by:jstoner49
12 Comments
 
LVL 2

Expert Comment

by:mikepj
ID: 7177674
Can you provide some code showing the trouble?  That should work.
0
 

Author Comment

by:jstoner49
ID: 7178859
Here is my code for printing. It prints fine to a local printer but it will not print the network printers.

procedure TForm1.Button20Click(Sender: TObject);
var
fprn: system.text;
I:integer;
Lcol: integer;
begin
      anquest;

    richedit1.Text:= print.Text;
 if printdialog1.Execute then
richedit1.Print(print.text);




end;
0
 
LVL 2

Expert Comment

by:mikepj
ID: 7178933
The Print() method parameter is the document title.  I wonder if this causes your printer driver to do something strange.
0
Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 

Author Comment

by:jstoner49
ID: 7178964
if I don't use (print.text) I get blank paper on the local printer. Print.text is a tmemo.
0
 
LVL 2

Expert Comment

by:mikepj
ID: 7178971
You have something odd going on.  Update your printer drivers.  I have previously done exactly what you have done and it worked great.
0
 

Author Comment

by:jstoner49
ID: 7178978
I'm using richedit.print because wordwrap on the printer.  
I have searching for something on several sites. One thing that keeps coming up is printerindex I'm still not sure how to write code with it.
0
 

Author Comment

by:jstoner49
ID: 7178981
these are current printer drivers for win 2000.  When printing to win2000 it always prompts you to select a printer even when the program already has selected the specific printer.  When I run the program it never launches the win 2000 printer select window. I don't even get an error and the print job is not even spooled.
0
 
LVL 2

Expert Comment

by:mikepj
ID: 7178985
You can use it to directly read/control the printer selection.  In conjunction with Printers[PrinterIndex], you can see the name of the printer.  I'm sure much more is readily available.  I did a quick test and PrinterIndex is set directly by TPrinterDialog so you won't need it unless you're making this selection yourself.
0
 

Author Comment

by:jstoner49
ID: 7185165
I'm not sure why the richedit would not print to the network printer I'm using the generic code I found for printing tmemo this seems to work just fine.
0
 

Expert Comment

by:CleanupPing
ID: 9343005
jstoner49:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 
LVL 5

Expert Comment

by:Lukasz Lach
ID: 9461499
jstoner49,
No comment has been added lately (18 days), so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area for this question:

RECOMMENDATION: Accept mikepj's answer http:#7178985 and Refund

Please leave any comments here within 7 days.

-- Please DO NOT accept this comment as an answer ! --

Thanks,

anAKiN
EE Cleanup Volunteer
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 9537815
PAQed, with points refunded (200)

Computer101
E-E Admin
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…

789 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