Title: Visual Basic
1Visual Basic
- An introduction
- By
- Tony Wilson
2Visual BASIC Environment
3Visual BASIC Environment
Control tool bar with default controls
4Visual BASIC Environment
Control tool bar with default controls
5Visual BASIC Environment
Form worksheet displaying the program screen
6Visual BASIC Environment
Directory of major project components
7Visual BASIC Environment
Properties window
8Visual BASIC Environment
Dropdown list of objects (whose properties can be
set).
9Visual BASIC Environment
Explanation of highlighted property
10Visual BASIC Environment
Diagram of where the program will appear on the
screen.
11Visual BASIC Environment
Code window showing code behind the objects
12Visual BASIC Environment
Dropdown list of objects
13Visual BASIC Environment
Dropdown list of events the object can respond to.
14Visual BASIC Controls
15Visual BASIC Controls Labeled
Pointer ? Label? Frame? CheckBox? ComboBox? HScrol
lBar? Timer? DirListBox? Shape? Image? OLE?
? PictureBox ? TextBox ? CommandButton ?
OptionButton ? ListBox ? VScrollBar ?
DriveListBox ? FileListBox ? Line ? Data
16Visual BASIC Controls Name Prefixes
Pointer ? lbl? fra? chk? cbo? hsb? tmr? dir? shp?
img? ole?
? pic ? txt ? cmd ? opt ? lst ? vsb ? drv ? fil ?
lin ? dat
17Visual BASIC Controls Name Prefixes
Pointer ? lbl? fra? chk? cbo? hsb? tmr? dir? shp?
img? ole?
? pic ? txt ? cmd ? opt ? lst ? vsb ? drv ? fil ?
lin ? dat
18Visual BASIC Controls Pointer
- Used to select things
- Click
- Drag
- Resize
- Etcetera
19Visual BASIC Controls Label
- Puts words on the screen
- Does not interact with user
- Can be made invisible or changed by the program
20Visual BASIC Controls Frame
- Used to group other objects
- Logically or just visually
- Need not be visible
- Draw the frame, then draw the objects in it.
- Especially useful with Option (Radio) buttons
21Visual BASIC Controls CheckBox
- Indicates selection
- Need not be part of a group
- Built-in caption mechanism
- 3 states
- Checked
- Not checked
- Grayed
22Visual BASIC Controls ComboBox
- Varieties of lists
- Visible/pulldown
- Can type in/must select from list
23Visual BASIC Controls Horizontal Scroll Bar
- Lets user set a value
- GUI view is horizontal
24Visual BASIC Controls Horizontal Scroll Bar
- Lets user set a value
- GUI view is Vertical
25Visual BASIC Controls Timer
- Not visible at runtime
- Triggers a Timer Event at a programmed interval