Interviews4 answers
How to reduce image resolution in C#?
4 Answers
using (Bitmap bitmap = (Bitmap)Image.FromFile("file.jpg")){using (Bitmap newBitmap = new Bitmap(bitmap)){newBitmap.SetResolution(300, 300);newBitmap.Save("file300.jpg", ImageFormat.Jpeg);}}
0
Anil SatapathyPosted Feb 27, 2017, 8:27 AM EST
Nice one
Anil SatapathyPosted Feb 27, 2017, 8:26 AM EST
hey
kindly try this.
https://www.codeproject.com/Questions/461866/Change-Image-Resolution
but i will suggest you use jquery for same
Naveen BishtPosted Feb 24, 2017, 7:21 PM EST
using (Bitmap bitmap = (Bitmap)Image.FromFile("file.jpg"))
{
using (Bitmap newBitmap = new Bitmap(bitmap))
{
newBitmap.SetResolution(300, 300);
newBitmap.Save("file300.jpg", ImageFormat.Jpeg);
}
}
Chinmaya DashPosted Jan 12, 2017, 3:01 AM EST

