BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Rave Reports (BaseReport.SelectPrinter)

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Thirdparty Tools (General)
View previous topic :: View next topic  
Author Message
Wim
Guest





PostPosted: Thu Sep 07, 2006 8:08 pm    Post subject: Rave Reports (BaseReport.SelectPrinter) Reply with quote



Hi,

I created some kind of automated printing using Rave Reports. I have the
code like this:

procedure tForm1.Button1(Sender: TObject);
begin
RvSystem1.execute;
end;

procedure tForm1.RvSystem1Print(Sender: TObject);
begin
with RvSystem1.Basereport do
begin

// Here comes the code for printing

end;
end;

This works perfect with the default printer, but I like to select the
printer automatically, because I want so sent one copy to the default
printer and a second copy to another printer in the network.
I already tried to use Basereport.Selectprinter(*printer*). But, depending
on where I put it, it didn't do anything or it created the error "Report
already printing".

Does anyone know a simple solution for this?

Thx, Wim.
Back to top
Bostontech
Guest





PostPosted: Fri Sep 08, 2006 7:18 am    Post subject: Re: Rave Reports (BaseReport.SelectPrinter) Reply with quote



Try using the BeforePrint Event.

I use this event to change margins. You can probably use it to change
the printer.
Back to top
L. S. Lichtmann
Guest





PostPosted: Sat Sep 09, 2006 4:52 am    Post subject: Re: Rave Reports (BaseReport.SelectPrinter) Reply with quote



Do the printer selection in the OnBeforePrint event

"Wim" <lostboy321 (AT) hotmail (DOT) com> wrote in message
news:450035db$1 (AT) newsgroups (DOT) borland.com...
Quote:
Hi,

I created some kind of automated printing using Rave Reports. I have the
code like this:

procedure tForm1.Button1(Sender: TObject);
begin
RvSystem1.execute;
end;

procedure tForm1.RvSystem1Print(Sender: TObject);
begin
with RvSystem1.Basereport do
begin

// Here comes the code for printing

end;
end;

This works perfect with the default printer, but I like to select the
printer automatically, because I want so sent one copy to the default
printer and a second copy to another printer in the network.
I already tried to use Basereport.Selectprinter(*printer*). But, depending
on where I put it, it didn't do anything or it created the error "Report
already printing".

Does anyone know a simple solution for this?

Thx, Wim.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Thirdparty Tools (General) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.