saving image problem

Steven Low

Active member
Joined
Apr 14, 2005
Messages
42
Programming Experience
1-3
Hi guys
the bottom method works

but again it saved it as a unknown file
Im not sure why thoo because it is set to save as a jpeg?


Dim Save As New SaveFileDialog()

' Configure the dialog
With Save
.InitialDirectory = "G:\"
.Filter = "Jpeg Files (*.jpg)/*.jpg*"

If .ShowDialog = DialogResult.OK Then

PictureBox2.Image.Save(.FileName, System.Drawing.Imaging.ImageFormat.Jpeg)
 

kulrom

Well-known member
Joined
May 10, 2005
Messages
2,854
Location
Republic of Macedonia
Programming Experience
10+
you shoud remove slash "/" from there and put "|" instead and also remove "*" behind extension

it should look like:

.Filter = "Jpeg Files (*.jpg)|*.jpg"

ok this is a demo that will demonstrate all that you need ...

Cheers :)
 

Attachments

  • SaveImageFromPBox.zip
    18.1 KB · Views: 70
Last edited:
Top Bottom