foreach (var a in lstr) { imgexts = a.Photo; if (imgexts != null) { imgname = Utility.Encrypt(string.Format(ComponentStockResearch.GetImageFormat(), a.StockResearchID)) + a.Photo; if (imgname != null) { spath = Server.MapPath(Request.ApplicationPath) + "gallery/large/" + imgname; if (System.IO.File.Exists(spath)) { ComponentImageResize objImg = new ComponentImageResize(); Bitmap bmpimage = new Bitmap(spath, false); System.Drawing.Image stockhome = objImg.CreateThumbNail(bmpimage, (int)ClsConvert.ToInt(Util.GetConfigKey("StockReaserch_List_W")), (int)ClsConvert.ToInt(Util.GetConfigKey("StockReaserch_List_H"))); stockhome.Save(Server.MapPath(Request.ApplicationPath) + "\\gallery\\StockResearchList\\" + imgname); //stockhome.Save(Server.MapPath(Request.ApplicationPath) + "\\gallery\\featuredarticlehome\\" + spath); } } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)