Abhilash J A

Abhilash J A

  • 533
  • 2.4k
  • 598.2k

some invalid argument in system.drawing.graphics c#

Jan 8 2017 12:26 AM
Hello everyone,
 
How can I solve this error?
 
 
 I have tried,
  1. private void PrintImageHandler(object sender, PrintPageEventArgs ppeArgs)  
  2.         {  
  3.  string[] ListViewItemsData = ListViewItemsCollections.Select(i => Convert.ToString(i.FilePath) + Convert.ToString(i.Parent_File_Name) + "_" + Convert.ToString(i.Child_File_Name)).ToArray();  
  4.             
  5.             List<Bitmap> images = new List<Bitmap>();  
  6.             foreach (var file in ListViewItemsData)  
  7.             {  
  8.                   images.Add(new Bitmap(file));  
  9.             }             
  10.   
  11.             if (images != null)  
  12.             {  
  13.                 ppeArgs.Graphics.DrawImageUnscaled(images, 0, 0);  
  14.             }              
  15.             ppeArgs.HasMorePages = (images != null);  
  16. }  
 Please help me.

Answers (2)