Click here to Skip to main content
15,898,538 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
So, i have an image in my picturebox in bmp format and i want to save it in jpg format to my documents folder using savefiledialog option. Can anyone help me with the code pls? Thanks
Posted
Comments
Animesh Datta 16-Jun-14 9:28am    
what have you tried ?
Surajit Das 16-Jun-14 9:33am    
The one i tried doesnt use the savefiledialog option but it works.
If Me.pbdraw.Image IsNot Nothing Then
Me.pbdraw.Image.Save(IO.Path.Combine(My.Computer.FileSystem.SpecialDirectories.MyPictures, "C:\temp\TestFile.jpg"))
End If
Richard MacCutchan 16-Jun-14 9:42am    
SaveFileDialog does not save files, it merely allows the user to select the location and name of the object being saved. And the MSDN documentation explains exactly how to use it.

1 solution

Your question is a very common task. You can find a lot if you try researching on google[^] before posting. One the results in that search goes to this forum[^] and it looks like just what you need.

Try to accomplish your task by doing the research first. Then if you are stuck with syntax or are getting a strange error message, post the error and the relevant code here and we can help you.


Hope this helps.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900