When you write a Visual Basic program, you first have to design the user interface. Essentially, a Visual Basic user interface consists of objects that you place on the screen and arrange in some semblance of organization so that the screen looks pretty.
The common elements of a Visual Basic user interface appear in Figure 1 and consist of the following:
- Forms (also known as windows)
- Buttons (such as command buttons and radio buttons)
- Boxes (such as text boxes and check boxes)
- Labels
- Pictures (such as icons and graphics)
![]() |
Figure 1: The elements of a typical Visual Basic user interface. |
To design your user interface, follow these steps:
1. Create a form.
2. Choose the object you want to draw from the Toolbox. (See Table 1.)
3. Draw the object on the form.
Table 1: Tools in the Visual Basic Toolbox
Icon | Tool Name | What This Tool Does |
![]() | Pointer | Selects objects |
![]() | Picture box | Draws a box to display graphics |
![]() | Label | Draws a box to display text |
![]() | Text box | Draws a box that can display text and let the user type in text |
![]() | Frame | Groups two or more objects together |
![]() | Command button | Draws a command button |
![]() | Check box | Draws a check box |
![]() | Option (or radio) button | Draws a radio button |
![]() | Combo box | Draws a combo box |
![]() | List box | Draws a list box |
![]() | Horizontal scroll bar | Draws a horizontal scroll bar |
![]() | Vertical scroll bar | Draws a vertical scroll bar |
![]() | Timer | Places a timer on a form |
![]() | Drive list box | Draws a drive list box that displays all the disk drives available |
![]() | Directory list box | Draws a directory list box that displays a directory on a particular disk drive |
![]() | File list box | Draws a file list box that displays files in a specific directory |
![]() | Shape | Draws a geometric shape such as a circle or a square |
![]() | Line | Draws a line |
![]() | Image box | Draws a box to display graphics |
![]() | Data control | Draws a control to link a program to a database file |
![]() | OLE | Draws a box to insert an OLE object |
dummies
Source:http://www.dummies.com/how-to/content/meeting-the-tools-in-the-visual-basic-toolbox.html
No comments:
Post a Comment