Openfd - Filter "Jpeg Images - .JPG - All Files - . "
Openfd - Filter "Jpeg Images - .JPG - All Files - . "
However, we still haven't inserted a new image. To place a selected image into the picture box, you have to get the file name that the user selected. You can add a string variable to your code for this: string Chosen_File = ""; You then access the FileName property of openFD. Like this: Chosen_File = openFD.FileName; The file name will then be in the variable we've called Chosen_File. To place a new image into the picture box you have on the form, you need the Image property: pictureBox1.Image To place your chosen file into the Image property, you need this: pictureBox1.Image = Image.FromFile(Chosen_File); So after the equals sign, you can use the Image object. This has a method called FromFile( ). In between the round brackets of this method, you type the name of the image file. For us, this image file is stored in our Chosen_File variable.