I found this method:
Graphics g = e.Graphics;
Bitmap bmp = new Bitmap("winter.jpg");
g.DrawImage(bmp, 0, 0);
Console.WriteLine("Screen resolution: " + g.DpiX + "DPI");
Console.WriteLine("Image resolution: " + bmp.HorizontalResolution + "DPI");
Console.WriteLine("Image Width: " + bmp.Width);
Console.WriteLine("Image Height: " + bmp.Height);
SizeF s = new SizeF(bmp.Width * (g.DpiX / bmp.HorizontalResolution),
bmp.Height * (g.DpiY / bmp.VerticalResolution));
Console.WriteLine("Display size of image: " + s);
But I don't really understand how to fetch what I'm looking for. I'm not interested in DPI, I just need the 1024x768, 1200x1024 etc numbers. Also, would I have to create a new image object every time I want to find the resolution of the image?
I'm making an application that lists current images in a given folder, so any help would be appreciated. :)