How do I display an image in a picturebox using a variable name?
string name = "photo.jpg";
pictureBox1.ImageLocation = name;
// or
Image image = Image.FromFile(name);
pictureBox1.Image = new Bitmap(image);
neither is working. I'm getting the small box with an x in it.
Any help? Thanks