44 Part I Getting Started with Microsoft Visual Basic 2010
- Drag the Label4 object below the two command buttons.
When you’ve finished, your four labels should look like those in the following
screen shot. (You can move your label objects if they don’t look quite right .)
Now you’ll add a picture box to the form to graphically display the payout you’ll receive
when you draw a 7 and hit the jackpot. A picture box is designed to display bitmaps, icons,
digital photos, and other artwork in a program. One of the best uses for a picture box is to
display a JPEG image file.
Add a picture
- Click the PictureBox control in the Toolbox.
- Using the control’s drawing pointer, create a large rectangular box below the second
and third labels on the form.
Leave a little space below the labels for their size to grow as I mentioned earlier.
When you’ve finished, your picture box object looks similar to this:
This object will be named PictureBox1 in your program; you’ll use this name later in
the program code.
Now you’re ready to customize your interface by setting a few properties.