コード例 #1
0
 public void SetImage(PictureBox picbox, String fileName)
 {
     try
     {
         try
         {
             picbox.Image = tb.GetThumbnail(fileName);
         }
         catch (Exception e)
         {
             picbox.Image = global::SortImage.Properties.Resources.thumberror;
             System.Diagnostics.Debug.WriteLine("Corrupt on transpanel:   " + e);
         }
         picbox.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
     }
     catch (Exception ex)
     {
         System.Diagnostics.Debug.WriteLine("Can't open file stream to load image for transpanel:   " + ex);
     }
 }
コード例 #2
0
ファイル: ImageViewer.cs プロジェクト: Stmdotcom/sortimg
 public void LoadImage(string imageFilename, ThumbnailBuilder tnb)
 {
     image         = tnb.GetThumbnail(imageFilename);
     imageLocation = imageFilename;
 }