How to Load any image in Picture box control
Posted on January 4, 2009
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | 'Controls - How to Load any image in Picture box control 'Using the LoadPicture function Picture1.Picture = LoadPicture("c:\windows\setup.bmp") 'Clear the current image using either one of the following statements: ' These are equivalent. Picture1.Picture = LoadPicture("") Set Picture1.Picture = Nothing 'LoadPicture function has been extended in Visual Basic 6 to support icon files 'containing multiple icons. The new syntax is the following: ' 'LoadPicture(filename, [size], [colordepth], [x], [y]) ' 'where values in square brackets are optional. ' 'To copy an image from one PictureBox control to another by assigning the target 'Control 's Picture property: Picture2.Picture = Picture1.Picture |
Related posts:
- How to load a picture in picture box by selecting the picture using Common dialog control.
- How to copy an image from one PictureBox control to another
- How to Copy and Paste the Picture
- How to stretch image in a Picture Box Control
- How to assign image from imagelist control to another control at runtime
- How to select/remove picture in a picture box
- How to stretch Picture Box
- How to remove Picture from PictureBox at Run-Time
- How to add Picture to PictureBox at Run-Time
- How to set background picture for form (like the background image of a HTML Document)