Save images?

Hello, I want to create a program that saves an image that is a part of the program to for example c:windows emp, is there anyone who knows how to do this?

Happy New Year everyone/
Rui Chen

Comments

  • : Hello, I want to create a program that saves an image that is a part of the program to for example c:windows emp, is there anyone who knows how to do this?
    :
    : Happy New Year everyone/
    : Rui Chen
    :

    Use the SavePicture statement.
  • : : Hello, I want to create a program that saves an image that is a part of the program to for example c:windows emp, is there anyone who knows how to do this?
    : :
    : : Happy New Year everyone/
    : : Rui Chen
    : :
    :
    : Use the SavePicture statement.
    :

    Thanks for your answer but, hmmm (embarassed) how do you use the SavePicture statement? I'm pretty new to VB so a more detailed answer would make me most grateful.

    /Rui Chen
  • : Thanks for your answer but, hmmm (embarassed) how do you use the SavePicture statement? I'm pretty new to VB so a more detailed answer would make me most grateful.
    :

    Only reason to be embarassed (that spelling just doesn't look right...) is if you didn't ask.

    Basically, you provide two arguements; the .Picture property of the control that contains the picture and a filename. If you want the temp folder, ask Windows for it using Environ$.

    [code]Dim Temp As String
    Temp = Environ$("temp")
    'Never assume a path does or doesn't end with a ""
    If Right$(Temp, 1) <> "" Then Temp = Temp & ""
    Temp = Temp & "SomeFilename.bmp"
    SavePicture Picture1.Picture, Temp
    [/code]

  • : : Thanks for your answer but, hmmm (embarassed) how do you use the SavePicture statement? I'm pretty new to VB so a more detailed answer would make me most grateful.
    : :
    :
    : Only reason to be embarassed (that spelling just doesn't look right...) is if you didn't ask.
    :
    : Basically, you provide two arguements; the .Picture property of the control that contains the picture and a filename. If you want the temp folder, ask Windows for it using Environ$.
    :
    : [code]Dim Temp As String
    : Temp = Environ$("temp")
    : 'Never assume a path does or doesn't end with a ""
    : If Right$(Temp, 1) <> "" Then Temp = Temp & ""
    : Temp = Temp & "SomeFilename.bmp"
    : SavePicture Picture1.Picture, Temp
    : [/code]
    :
    :
    Thanka a lot for your codes and your time. I'm most grateful.

    :-D / Rui Chen
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories