PDA

Click to See Complete Forum and Search --> : a simple question


Wolverine
May 7th, 2001, 02:24 AM
If I have a image in a picture box NOT loaded with Picture1.picture = Loadpicture("C:\Directory\Filename.bmp") I loaded the picture from the propierties of the picture box how can i save the image to a disk with other name?
Here my code :
Private sub Command1_Click
Picture1.Picture = Picture1.Image
SavePicture Picture1.Image, "C.\Windows\Escritorio\PRUEBA.bmp"
End sub

But when I click the Command Button I got the message
"Path not found"
How can I do that??
Thanks
Wolverine

sunnyl
May 7th, 2001, 02:29 AM
Try another directory when saving.

I believe that it cannot save to a directory that doesn't exist.

pjvdg
May 7th, 2001, 10:36 AM
I don't know if you already noticed it but you typed:
C.\
Guess what this should be, C:\ maybe? :D

Sastraxi
May 7th, 2001, 03:39 PM
Use:

[code]
Private Sub Command1_Click()
Picture1.Picture = Picture1.Image
MkDir "C:\Windows\Escritorio\PRUEBA.bmp"
SavePicture Picture1.Image, "C:\Windows\Escritorio\PRUEBA.bmp"
End Sub

Sastraxi
May 7th, 2001, 03:39 PM
Use:


Private Sub Command1_Click()
Picture1.Picture = Picture1.Image
MkDir "C:\Windows\Escritorio\PRUEBA.bmp"
SavePicture Picture1.Image, "C:\Windows\Escritorio\PRUEBA.bmp"
End Sub