1 / 4

The PictureBox Control

The PictureBox Control. Prefix – pic Image Property – Changes the image or file that appears inside of the PictureBox SizeMode – can be set to either Normal. StretchImage, AutoSize, or CenterImage Visible – Can be set to either True or False. Size – is the picture box size in pixels.

bayard
Download Presentation

The PictureBox Control

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. The PictureBox Control • Prefix – pic • Image Property – Changes the image or file that appears inside of the PictureBox • SizeMode – can be set to either Normal. StretchImage, AutoSize, or CenterImage • Visible – Can be set to either True or False. • Size – is the picture box size in pixels.

  2. PictureBox cont… • A click event procedure can be coded for the picturebox. • Images for a project should be copied to the bin folder located in the project folder. • The image in a picturebox can be changed at run time by using the Image class in a statement similar to: Me.picNameofImage.Image = Image.FromFile(“NameofFile.bmp”) • The FromFile() method in the Image class creates and image object.

  3. Timer • Prefix – tmr • Interval – is the amount of time that passes before the Tick event procedure is executed. Interval is specified in milliseconds between 0 and 64,767 where 1,000 equals 1 second. • Enabled – is set to True to allow a Tick event to occur at the end of each interval.

  4. Timer Event Procedure • A Tick event procedure is coded for each timer object added to an application. • A Tick event occurs after the time specified in the Interval property elapses. For example, if the Interval is set to 1000, then a Tick event occurs every second. • Start() – starts a timer and can be used instead of the Enabled property. Timer.Start() • Stop() – stops a timer. Timer.Stop()

More Related