Results 1 to 2 of 2

Thread: Local variable containing an image...

  1. #1

    Thread Starter
    New Member
    Join Date
    Apr 2000
    Posts
    9

    I am currently loading 16 Image controls to hold transparent .GIF files. I was wondering if there is a way that I use the LoadPicture to load the four possible graphics, and then display as needed by altering the Picture property of the Image Control? Below is an example of what information I'm missing...



    dim myImage as <I don't know the type...>

    myImage = LoadPicture("Image.GIF"

    imgControl.Picture = myImage


    Can someone please give me a hand filling in the blank spaces?

    Daryl Jones
    Daryl Jones
    Software Developer
    [email protected]

  2. #2
    Junior Member
    Join Date
    Mar 1999
    Posts
    27
    No problem - just dim your variable As Object, like so:

    Code:
        Dim objPic As Object
        Set objPic = LoadPicture(PicPath)
        Picture1.Picture = objPic
    PicPath is the path to the image... I tested with a BMP, and I assume if LoadPicture works with GIF files, then the above should work... Good Luck!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width