Chapter 3 Quick Reference


Chapter 3 Quick Reference

To

Do this

Create a text box

Click the TextBox control, and draw the box.

Create a button

Click the Button control, and draw the button.

Change a property at run time

Change the value of the property by using program code. For example:

Label1.Text = "Hello!"

Create a radio button

Use the RadioButton control. To create multiple radio buttons, place more than one button object inside a box that you create by using the GroupBox control.

Create a check box

Click the CheckBox control, and draw a check box.

Create a list box

Click the ListBox control, and draw a list box.

Create a drop-down list box

Click the ComboBox control, and draw a drop-down list box.

Add items to a list box

Include statements with the Add method in the Form1_Load event procedure of your program. For example:

ListBox1.Items.Add "Printer"

Use a comment in code

Type a single quotation mark (') in the Code Editor, and then type a descriptive comment that will be ignored by the compiler. For example:

' Use the Process.Start method to start IE

Display a Web page

Create a link to the Web page by using the LinkLabel control, and then open the link in a browser by using the Process.Start method in program code.



Microsoft Visual Basic 2005 Step by Step
Microsoft Visual Basic 2005 Step by Step (Step by Step (Microsoft))
ISBN: B003E7EV06
EAN: N/A
Year: 2003
Pages: 168

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net