vb-components - CIS 338: VB.NET Components Dr. Ralph D....

Info iconThis preview shows pages 1–8. Sign up to view the full content.

View Full Document Right Arrow Icon
CIS 338: VB.NET Components Dr. Ralph D. Westfall April, 2009
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Components = Building Blocks form is the fundamental VB.NET component = interface between user and other code parts of a form control box (click or double-click upper left corner) Text (title) property title bar small buttons: minimize, maximize, close design grid (dots seen during development)
Background image of page 2
Form Methods if only one form, shows at Startup can stop it by clicking small Close (x) button at top right, or run Close in code do NOT use [frmname].Hide with only one form [frmname.]Close closes form, and also shuts down the project if there is only one form End shuts down the project if there is more than one form
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Controls visible objects on forms or elsewhere built into Visual Basic.NET or available from 3 rd parties examples of built in form controls Button, TextBox, Label, CheckBox, RadioButtons, ListBox, ComboBox, etc. (view names on Visual Studio.NET Toolbox buttons)
Background image of page 4
Commonly Used VB.NET Controls Label – puts text on a form TextBox – accepts inputs, displays outputs (Command) Button – causes code to run CheckBox – accepts Yes/No inputs (Option) RadioButtons – selects only one from multiple choices ListBox – select from a list of choices ComboBox – select from list or enter
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Sample Properties of Controls properties = variables e.g., (Name) of form or control Location.X .Y = # of pixels from left and top edges of “container” sets position on screen container = what item is inside a form is the container for Button, etc. Size: Width Height are also in pixels Anchor – attaches to side(s) of the form
Background image of page 6
- 2 more properties Enabled – True means user can change for a Text Box that shows a calculated output, set Enabled = False (or show output in a Label instead) Visible = True (or False) guess what this does where use? why? 'code
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 8
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 30

vb-components - CIS 338: VB.NET Components Dr. Ralph D....

This preview shows document pages 1 - 8. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online