Visual Basic 2005: Your visual blueprint for writing dynamic applications
Buy Rights Online Buy Rights

Rights Contact Login For More Details

More About This Title Visual Basic 2005: Your visual blueprint for writing dynamic applications

English

Jim Keogh is on the faculty of Columbia University and Saint Peter’s College in Jersey City, New Jersey. He developed the e-commerce tract at Columbia University. Jim has spent decades developing applications for major Wall Street corporations and is the author of more than 70 books, including Java Database Programming For Dummies, Unix Programming For Dummies, and Linux Programming For Dummies.

English

1 GETTING STARTED WITH VB.NET 2

Install Visual Studio 2005 2

Create a New Project 6

Using Parts of a Project 8

Create a “Hello World” Application 10

2 WORKING WITH WINDOWS FORMS 12

Create a New Form 12

Add a Control to a Form 13

Set the Properties of a Control 14

Resize a Control 16

Create a Menu 17

Create a Dialog Box 18

Set the Tab Key Order 20

Create a Message Box 22

Write Code for an Event 23

3 CREATING WINDOWS CONTROLS: LABELS, TEXT BOXES, AND LISTS 24

Add a TextBox Control to a Form 24

Access a TextBox Control 26

Set Defaults for a TextBox Control 28

Add a Label Control to a Form 30

Add a ListBox Control 32

Set Defaults for a ListBox Control 34

Write Items to a ListBox Control 36

Access an Item Selected from a ListBox Control 38

Add a ComboBox Control 40

Access an Item Selected from a ComboBox Control 42

4 CREATING WINDOWS CONTROLS: BUTTONS, RADIO BUTTONS, AND CHECK BOXES 44

Add a Button Control 44

Write a Button Control Event 45

Change the Label of a Button Control 46

Using an Image for a Button Control 47

Make a Button the Default Button 48

Add a Radio Button 50

Access a Radio Button 52

Add a Check Box 54

Access a Check Box 56

Create a GroupBox Control 58

5 DECLARING VARIABLES, EXPRESSIONS, AND STATEMENTS 60

Understanding Variable Types 60

Declare a Variable 62

Initialize a Variable 63

Assign a Value to a Variable 64

Using Variables 65

Change the Value of a Variable 66

Convert Data Types 68

Create a Simple Expression 70

Create a Complex Expression 71

Using Operator Precedence 72

Create a Statement 73

Create More Complex Expressions 74

6 CREATING CONDITIONAL STATEMENTS 76

Understanding Conditional Statements 76

Create an If...Then Statement 78

Create an Equivalent Logical Expression 80

Create a Not Equivalent Logical Expression 82

Create a Compound Logical Expression 84

Create an If...Then...Else Statement 86

Create an If...Then...ElseIf...Then Statement 88

Create an If...Then...ElseIf...Then...Else Statement 90

Create a Nested If...Then Statement 92

Create a Select Case Statement 94

Create a Select Case...Case Else Statement 96

7 CREATING LOOPS 98

Create a For Loop 98

Increment a For Loop by a Set Value 100

Create a Do While Loop 102

Create a Do Until Loop 104

Create a Do Loop While Loop 106

8 DECLARING ARRAYS 108

Declare an Array 108

Initialize an Array 110

Assign a Value to an Array 112

Access the Value of an Array Element 114

Declare a Multidimensional Array 116

Assign a Value to a Multidimensional Array 118

Access Elements of a Multidimensional Array 120

Sort an Array 122

Search Array Elements 124

Size an Array 126

Create a Dynamic Array 128

Pass an Array to a Subroutine or Function 130

Return an Array from a Function 132

Change an Array Value Using ByRef 134

9 DEFINING SUBROUTINES AND FUNCTIONS 136

Define a Subroutine 136

Call a Subroutine 138

Create Parameters for a Subroutine 140

Pass Parameters to a Subroutine 142

Define a Function 144

Call a Function 146

10 UNDERSTANDING DATABASES 148

Understanding Database Design 148

An Introduction to ADO.NET 150

Understanding Data, Tables, and a Database 152

Connect to a Database 154

Configure the Data Source 156

Using the Data Sources Window 158

Using SQL Statements 160

Using the DataGrid View Control 162

Remove a Column from the Data Grid View 164

Add a Column to the Data Grid View 166

Change the Color of Every Other Row 168

Save Changes Made to the Data Grid View 170

Save Changes to a Database Using a Button Control 172

Add a SQL Query to the Data Grid View 174

Using Code to Bind Data to a Combo Box 176

Using the ReportViewer Control 178

11 DEBUGGING YOUR APPLICATION 180

Set Breakpoints 180

Using the Watch Window 182

Using a Visualizer 184

12 USING CLASSES 186

Create a Class and Declare an Object 186

Create a Sub Method for a Class 188

Create a Function Method for a Class 190

Create a Private Method 192

Create a Protected Method 194

Create a New() Method 196

Call a Method of a Class 198

Pass a Value to a Method of a Class 200

Assign a Value to a Public Property 202

Create a Property Procedure for a Class 204

Get a Value of a Property Procedure 206

Set a Value of a Property Procedure 208

Validate a Property Value 210

Inherit a Class 212

Using Overloading 214

Using Multiple Inheritance 216

13 CREATING COMPONENTS 218

An Introduction to Component Creation 218

Create a Component 220

Create a Windows Forms Control 222

Handle Default Properties 224

Add a Member 226

Add an Event 228

Using Standard Controls 230

Create a Control from Scratch 232

Reference a Library 234

14 CREATING GRAPHICS 236

Add a Picture to a Form 236

Using the Color Dialog Box 238

Understanding the Graphics Object 240

Create a Brush 242

Create a Pen 244

Draw Bitmaps and Images 246

Draw Simple Primitives 248

Draw a Curve 250

Draw Text 252

Create a Path 254

Using Regions 256

Create a Shaped Window 258

15 PROVIDING INPUT AND OUTPUT 260

Using a File Stream 260

Read from a Stream 262

Write to a Stream 263

Watch for File System Changes 264

Access File Information 266

Access Directory Information 268

Provide a File Dialog Box 270

Using the PrintDocument Control 272

Using the Printer Dialog Box 274

Using the Page Setup Dialog Box 276

Create a Print Preview 278

Download from a Web Server 280

Make a Connection to a Server 282

Accept Incoming Connections 284

16 PACKAGING YOUR APPLICATION 286

Create a Setup Program 286

Create a Shortcut for Your Application 288

Create an Icon for Your Application 290

Run the Setup Program 292

INDEX 294

loading