ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Printer Setup ImageEnMView
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

izaque

Brazil
95 Posts

Posted - Mar 13 2012 :  07:32:14  Show Profile  Reply
Good morning, how can I configure the printer setup ImageEnMView to be able to print many pages?
For example 100 pages, I want to print from 10 to 93. Can you help?

fab

1310 Posts

Posted - Mar 13 2012 :  08:41:57  Show Profile  Reply
Good morning,
using code:
Printer.BeginDoc();
for imageIndex:=9 to 92 do
  ImageEnMView1.MIO.PrintImage(imageIndex);
Printer.EndDoc();


Using dialog (DoPrintPreviewDialog) you have to select the images to print and then select Print Selected Images in the dialog:
ImageEnMView1.EnableMultiSelect := true;
ImageEnMView1.MultiSelecting := true;
for imageIndex:=9 to 92 do
  ImageEnMView1.SelectedImage := imageIndex;
ImageEnMView1.MultiSelecting := false;
ImageEnMView1.MIO.DoPrintPreviewDialog();
Go to Top of Page

izaque

Brazil
95 Posts

Posted - Mar 13 2012 :  11:48:49  Show Profile  Reply
Okay, but now I have a problem when I walk by "ImageEnMView1.MIO.PrintImage (ImageIndex)." It released the following exception:
"Currently Printer is not printing."
What would be the "Printer.BeginDoc ()" and "Printer.EndDoc ()"?
Go to Top of Page

fab

1310 Posts

Posted - Mar 13 2012 :  12:02:01  Show Profile  Reply
Please try this:
Printer.BeginDoc();
for imageIndex:=9 to 92 do
begin
  ImageEnMView1.MIO.PrintImage(imageIndex, Printer.Canvas); // << added Printer.Canvas
  Printer.NewPage();   // << added this
end;
Printer.EndDoc();
Go to Top of Page

izaque

Brazil
95 Posts

Posted - Mar 13 2012 :  12:13:45  Show Profile  Reply
Ok, Thanks!
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: