Anda di halaman 1dari 19

VB.

NET
Fundamentals
By: Paul D. Sheriff

3rd Edition March 2006


Published By: PDSA, Inc.

Copyright 2002-2006, PDSA, Inc.


All Rights Reserved, Worldwide

Introduction

Written By:

Paul D. Sheriff

Technical Editors:

Paul D. Sheriff

Every effort has been made to supply complete and accurate


information. However, PDSA, Inc. assumes no responsibility for its
use, nor for any infringement of the intellectual property rights of third
parties which would result from such use.

Copyright 2002-2006 PDSA, Inc.


All rights reserved worldwide. No part of this publication may be
stored in a retrieval system, transmitted, or reproduced in any way,
including but not limited to photocopy, photograph, magnetic or other
record, without the prior agreement and written permission of the
publisher.

Printed in the United States of America

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

E-Book Payment Notice - PLEASE READ

E-Book Payment Notice - PLEASE


READ
This e-book is sold on a per reader basis. This means that you have
the right to read this book as many times as you wish on any
computer that you wish to read it on. However, you may not share it
with anyone else.
I have kept the cost of this e-book low in order to keep it within the
budget of most readers. By purchasing this e-book, and encouraging
others to purchase this e-book, I will be able to keep writing more of
these.

Thank you for your support.

Sincerely,

Paul D. Sheriff

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Introduction

Table of Contents
E-Book Payment Notice - PLEASE READ ............................................................3
Table of Contents ..................................................................................................4
Introduction ..........................................................................................................15
Goals of this eBook..................................................................................16
Prerequisites ............................................................................................16
Assumptions ............................................................................................17
Technical Support................................................................................................17
Installation............................................................................................................17
If you have Problems Installing the Sample.........................................................18
About Paul D. Sheriff ...........................................................................................18
Chapter 1....................................................................................................................... 1-1
Overview of the Visual Basic Language ......................................................................... 1-1
Introduction ........................................................................................................ 1-2
What is Visual Basic .......................................................................................... 1-2
A Visual Basic Application ................................................................................. 1-3
Windows Forms ..................................................................................... 1-3
Web Forms ............................................................................................ 1-4
Classes .................................................................................................. 1-4
Procedures & Functions......................................................................... 1-4
Three Steps to Creating an Application ................................................. 1-5
What is Microsoft.NET ....................................................................................... 1-5
Overview of .NET Framework and its significance ............................................ 1-6
The Common Language Runtime...................................................................... 1-6
The .NET Classes.............................................................................................. 1-7
Common Language Specification.................................................................... 1-10
Services in .NET .............................................................................................. 1-10
History of Visual Basic ..................................................................................... 1-11
The Visual Basic Time-Line ................................................................. 1-11
Features of Visual Basic .................................................................................. 1-12

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Table of Contents
Visual Basic Advantages ..................................................................... 1-13
Visual Basic Disadvantages................................................................. 1-13
Future of Visual Basic...................................................................................... 1-14
Competition.......................................................................................... 1-14
Visual Basic Application Types........................................................................ 1-14
Windows Application............................................................................ 1-14
Class Library ........................................................................................ 1-15
Windows Control Library...................................................................... 1-15
ASP.NET Web Application................................................................... 1-15
ASP.NET Web Service ........................................................................ 1-15
Web Control Library ............................................................................. 1-15
Console Application ............................................................................. 1-16
Windows Service ................................................................................. 1-16
Smart Device Applications ................................................................... 1-16
SQL Server Project .............................................................................. 1-16
Visual Basic Application Components ............................................................. 1-16
Solutions .............................................................................................. 1-17
Projects ................................................................................................ 1-17
.VB Files............................................................................................... 1-17
.RESX Files.......................................................................................... 1-17
.ASPX Files.......................................................................................... 1-18
.ASCX Files.......................................................................................... 1-18
Programming Applications for Windows .......................................................... 1-18
Procedural Programming ..................................................................... 1-18
Event-driven Programming .................................................................. 1-19
Messages............................................................................................. 1-19
Events .................................................................................................. 1-19
Message Queue................................................................................... 1-20
Focus ................................................................................................... 1-21
Summary ......................................................................................................... 1-22
Chapter 2....................................................................................................................... 2-1
Introduction to Visual Studio.NET.................................................................................. 2-1
Using Visual Studio .NET .................................................................................. 2-2
Configuring Visual Studio .NET ......................................................................... 2-2
Visual Studio Start Page ........................................................................ 2-3
Creating a New Project...................................................................................... 2-4
Project Templates.............................................................................................. 2-6
Visual Studio Integrated Development Environment (IDE)................................ 2-6
Toolbox Window .................................................................................... 2-7

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Introduction
Solution Explorer Window...................................................................... 2-9
Properties Window............................................................................... 2-10
Object Browser Window....................................................................... 2-11
Task List Window................................................................................. 2-12
Using Help ....................................................................................................... 2-13
Dynamic Help Window......................................................................... 2-13
Contents Window................................................................................. 2-14
Index Window ...................................................................................... 2-15
Search Window.................................................................................... 2-16
Using the Editor ............................................................................................... 2-17
Using IntelliSense to Enter Code ......................................................... 2-18
Using Snippets..................................................................................... 2-18
Split the Editing Window ...................................................................... 2-19
Finding Text ......................................................................................... 2-20
Replace Text........................................................................................ 2-21
Block Comment/Uncomment ............................................................... 2-22
Dragging and Dropping Text................................................................ 2-23
Summary ......................................................................................................... 2-24
Chapter 3....................................................................................................................... 3-1
Introduction to Object Oriented Programming .............................................................. 3-1
Introduction to Object-Oriented Programming ................................................... 3-2
What is an Object?................................................................................. 3-2
The Sacred Buzzwords.......................................................................... 3-2
Working with Classes and Objects .................................................................... 3-4
What is a Class? .................................................................................... 3-4
Classes in VB.NET ................................................................................ 3-4
What is an Object?................................................................................. 3-4
Creating Objects .................................................................................... 3-5
What's the Difference between a Class and an Object?........................ 3-6
Properties............................................................................................... 3-7
Methods ................................................................................................. 3-8
And Events, Too .................................................................................... 3-9
Shared vs. Instance ............................................................................... 3-9
Constructors and Destructors .......................................................................... 3-11
Constructors......................................................................................... 3-11
Destructors........................................................................................... 3-14
Summary ......................................................................................................... 3-16
Chapter 4....................................................................................................................... 4-1
Controls.......................................................................................................................... 4-1

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Table of Contents
Introduction ........................................................................................................ 4-2
Controls ............................................................................................................. 4-2
Adding Controls to the Form .................................................................. 4-2
Controls in the ToolBox.......................................................................... 4-3
Resizing and Moving Controls ............................................................... 4-5
Properties Common to Forms and most Controls.................................. 4-6
The Employee Information Form ........................................................... 4-7
Label Control ..................................................................................................... 4-8
Common Label Control properties ......................................................... 4-8
Text Box Control ................................................................................................ 4-9
Common TextBox Properties................................................................. 4-9
Additional notes on the Text Box ......................................................... 4-10
Button Controls ................................................................................................ 4-10
Button Control Common Properties ..................................................... 4-11
GroupBox Control ............................................................................................ 4-12
Common GroupBox Properties............................................................ 4-12
RadioButton Control ........................................................................................ 4-12
Common RadioButton Properties ........................................................ 4-13
CheckBox Control............................................................................................ 4-13
Common CheckBox Properties............................................................ 4-14
PictureBox Control........................................................................................... 4-14
Common PictureBox Control Properties .............................................. 4-14
Summary ......................................................................................................... 4-16
Chapter 5....................................................................................................................... 5-1
Event Driven Programming Basics ................................................................................. 5-1
Introduction to Events ........................................................................................ 5-2
Code Window .................................................................................................... 5-2
Breakdown of an Event Procedure .................................................................... 5-4
Why use events? ................................................................................... 5-5
Changing Properties at Runtime............................................................ 5-5
Form Events ...................................................................................................... 5-6
New (Constructor) Method..................................................................... 5-6
Load Event............................................................................................. 5-6
Resize Event.......................................................................................... 5-7
Activated Event ...................................................................................... 5-7
Deactivated Event.................................................................................. 5-8
Closing Event......................................................................................... 5-8
Closed Event.......................................................................................... 5-9

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Introduction
Label Events ...................................................................................................... 5-9
Text Box Events................................................................................................. 5-9
TextChanged Event ............................................................................... 5-9
Command Button Events................................................................................. 5-10
Click Event ........................................................................................... 5-10
GroupBox Events............................................................................................. 5-10
RadioButton Events ......................................................................................... 5-10
CheckChanged Event .......................................................................... 5-10
CheckBox Events ............................................................................................ 5-11
CheckChanged Event .......................................................................... 5-11
ListBox Events ................................................................................................. 5-11
SelectedIndexChanged Event ............................................................. 5-11
ComboBox Events ........................................................................................... 5-12
Menu Events.................................................................................................... 5-13
Click Event ........................................................................................... 5-13
Select Event......................................................................................... 5-13
Summary ......................................................................................................... 5-14
Chapter 6....................................................................................................................... 6-1
Variables........................................................................................................................ 6-1
Introduction ........................................................................................................ 6-1
What is a Variable.............................................................................................. 6-2
Data Types ........................................................................................................ 6-2
True and False....................................................................................... 6-4
Declaring Variables............................................................................................ 6-4
One-Line Declarations ........................................................................... 6-5
Assigning values to Variables............................................................................ 6-5
Scope and Lifetime of a Variable....................................................................... 6-7
Where you can Declare Variables ......................................................... 6-7
Limit your scope..................................................................................... 6-8
Examples of Scope............................................................................................ 6-8
Procedure Scoped Variables ................................................................. 6-9
Block Scoped Variables ....................................................................... 6-10
What is a Member Variable.................................................................. 6-11
Option Explicit ...................................................................................... 6-11
Static Variables .................................................................................... 6-12
Naming Variables ............................................................................................ 6-12
Variable Naming Standards ................................................................. 6-12

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Table of Contents
Scope Prefixes..................................................................................... 6-14
The Object Data Type...................................................................................... 6-14
Numeric strings .................................................................................... 6-15
Option Strict ......................................................................................... 6-16
Summary ......................................................................................................... 6-17
Chapter 7....................................................................................................................... 7-1
Operators ....................................................................................................................... 7-1
Introduction ........................................................................................................ 7-1
What is an operator ........................................................................................... 7-2
Mathematical Operators .................................................................................... 7-2
Additional Operators .............................................................................. 7-4
Relational or Comparison Operators ................................................................. 7-4
Order of precedence.......................................................................................... 7-5
Example of precedence ......................................................................... 7-6
Summary ........................................................................................................... 7-7
Chapter 8....................................................................................................................... 8-1
Flow Control & Logic Structures..................................................................................... 8-1
Introduction ........................................................................................................ 8-2
If...Then.............................................................................................................. 8-2
If...Then...End If ..................................................................................... 8-3
The Else Clause..................................................................................... 8-3
The ElseIf Clause................................................................................... 8-4
IIf() Function........................................................................................... 8-4
Select Case ....................................................................................................... 8-5
Compiler Directives............................................................................................ 8-7
Built-In Compiler Constants ................................................................... 8-7
#If...Then...#Else...#End If ..................................................................... 8-8
Creating Compiler Constants................................................................. 8-8
Project-Wide Compiler Constants.......................................................... 8-9
Looping In VB .................................................................................................. 8-11
Do While Loop ..................................................................................... 8-11
Loop While ........................................................................................... 8-12
Do Until Loop ....................................................................................... 8-13
Loop Until............................................................................................. 8-13
For...Next Loops .............................................................................................. 8-14
For/Next Step Clause........................................................................... 8-15
Nested Constructs ........................................................................................... 8-16

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Introduction
Exit For/Exit Do................................................................................................ 8-16
Exit Sub/Exit Function...................................................................................... 8-17
With...End With ................................................................................................ 8-18
Summary ......................................................................................................... 8-19
Chapter 9....................................................................................................................... 9-1
Methods ......................................................................................................................... 9-1
Introduction ........................................................................................................ 9-2
Why Use Methods ............................................................................................. 9-2
Sub Procedures ................................................................................................. 9-3
Naming Procedures ............................................................................... 9-3
Event/Sub Procedures ........................................................................... 9-3
Scope of Procedures ............................................................................. 9-3
Creating a Procedure............................................................................. 9-4
Calling Procedures................................................................................. 9-4
Sub Main() Procedure........................................................................................ 9-4
Functions ........................................................................................................... 9-5
Creating a Function................................................................................ 9-6
Calling Functions ................................................................................... 9-6
Parameters ........................................................................................................ 9-7
Defining Arguments in your Procedures ................................................ 9-8
Calling Procedures with Parameters...................................................... 9-8
Parameters in Functions ........................................................................ 9-9
Calling Functions with Parameters ........................................................ 9-9
Call by Value and Call by Reference ............................................................... 9-10
Call By Value ....................................................................................... 9-10
Call By Reference ................................................................................ 9-12
Optional Arguments ......................................................................................... 9-14
Built-in Methods on Data Types....................................................................... 9-15
String Methods..................................................................................... 9-15
Numeric Methods................................................................................. 9-16
Date Methods....................................................................................... 9-16
Summary ......................................................................................................... 9-18
Chapter 10................................................................................................................... 10-1
Arrays and Constants................................................................................................... 10-1
Arrays .............................................................................................................. 10-2
Using Arrays .................................................................................................... 10-3
Converting a String to an Array............................................................ 10-3

10

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Table of Contents
Retrieving a List of Files....................................................................... 10-4
Retrieving a List of Folders .................................................................. 10-5
Retrieving Lines of Text ....................................................................... 10-5
Creating Your Own Arrays............................................................................... 10-6
Fixed-Size Arrays................................................................................. 10-6
Dynamic Arrays.................................................................................... 10-7
Preserving Array Contents................................................................... 10-8
Initializing Arrays at Declaration Time.................................................. 10-9
Misc Array Topics .......................................................................................... 10-10
Array References ............................................................................... 10-11
Copying an Array ............................................................................... 10-11
Cloning an Array ................................................................................ 10-12
Clearing an Array ............................................................................... 10-13
Passing an Array to a Method............................................................ 10-13
Sorting an Array ................................................................................. 10-14
Searching an Array ............................................................................ 10-15
Multi-Dimensional Arrays............................................................................... 10-15
Constants....................................................................................................... 10-16
Summary ....................................................................................................... 10-18
Chapter 11................................................................................................................... 11-1
Introduction to ADO.NET ............................................................................................. 11-1
Getting Started with ADO.NET ........................................................................ 11-2
Using ADO.NET Classes ..................................................................... 11-4
ADO.NET Namespaces ....................................................................... 11-4
Benefits of ADO.NET....................................................................................... 11-6
Performance ........................................................................................ 11-6
Scalability............................................................................................. 11-6
Interoperability ..................................................................................... 11-7
Programmability ................................................................................... 11-7
Summary ......................................................................................................... 11-9
Chapter 12................................................................................................................... 12-1
DataBinding on Windows Forms .................................................................................. 12-1
ADO.NET Data Binding ................................................................................... 12-2
Binding Data to a DataGrid.............................................................................. 12-3
Create the Sample Form...................................................................... 12-3
Use the Data Sources Windows .......................................................... 12-4
Create the User Interface................................................................... 12-10
Try It Out ............................................................................................ 12-11

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

11

Introduction
Working with Combo Boxes........................................................................... 12-12
Adding a Second DataSet to the Form .............................................. 12-12
Try It Out ............................................................................................ 12-15
What's Different From VB6 ............................................................................ 12-16
Summary ....................................................................................................... 12-18
Chapter 13................................................................................................................... 13-1
Creating Classes........................................................................................................... 13-1
Overview of Classes ........................................................................................ 13-2
Good Uses for Classes ........................................................................ 13-3
Creating a Class .............................................................................................. 13-3
Steps to Create the Form..................................................................... 13-4
Create the LineData Class................................................................... 13-5
Creating Properties.......................................................................................... 13-5
Create a Method ............................................................................................ 13-10
Passing Data to a Constructor....................................................................... 13-12
Use Classes for All Your Tasks ......................................................... 13-14
What is a namespace? .................................................................................. 13-14
What's New in VB.NET .................................................................................. 13-15
Summary ....................................................................................................... 13-16
Chapter 14................................................................................................................... 14-1
The StringBuilder Class............................................................................................... 14-1
Introduction to StringBuilder ............................................................................ 14-2
What is the StringBuilder Class ........................................................... 14-2
Some Background ............................................................................... 14-2
Using the StringBuilder Class .......................................................................... 14-3
Appending data.................................................................................... 14-5
Checking the Capacity and Length ...................................................... 14-6
Using Formatting with AppendFormat ................................................. 14-6
Working with Characters...................................................................... 14-7
Inserting Data into the String ............................................................... 14-7
Removing Data from the String............................................................ 14-8
Replacing Data in the String ................................................................ 14-8
Summary ....................................................................................................... 14-10
Chapter 15................................................................................................................... 15-1
Working with the MessageBox Class .......................................................................... 15-1
Working with MessageBox .............................................................................. 15-2
Why Would I Want to Do This?............................................................ 15-2

12

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Table of Contents
Objective .............................................................................................. 15-3
Steps.................................................................................................... 15-3
Comments............................................................................................ 15-7
Summary ......................................................................................................... 15-8
Chapter 16................................................................................................................... 16-1
Creating Dialog Forms ................................................................................................. 16-1
Creating Dialog Box Forms.............................................................................. 16-2
Objective .............................................................................................. 16-2
Steps to Create the Form..................................................................... 16-3
Returning a Result from the Dialog Form ............................................ 16-4
Closing the Dialog Automatically ......................................................... 16-5
Loading the Login Form ....................................................................... 16-5
Comments............................................................................................ 16-7
Summary ......................................................................................................... 16-8
Chapter 17................................................................................................................... 17-1
Working with MDI Forms ............................................................................................. 17-1
MDI Overview .................................................................................................. 17-2
Single Document Interface................................................................... 17-2
Uses of MDI ......................................................................................... 17-3
Creating an MDI Parent Form.............................................................. 17-3
Runtime Features of MDI Child Forms ................................................ 17-4
Create an MDI Project ..................................................................................... 17-5
Create the MDI Parent Form................................................................ 17-5
Creating Menus ............................................................................................... 17-6
Creating Names for Each Menu........................................................... 17-8
Display a Child Form............................................................................ 17-9
Differentiating Between Child Windows ............................................. 17-10
Child Menus in MDI Applications ....................................................... 17-11
Working with MDI Child Forms ...................................................................... 17-14
Tracking Child Windows .................................................................... 17-16
Creating Pop-Up Menus ................................................................................ 17-17
Manipulating Menus at Runtime .................................................................... 17-19
Checking and Unchecking Menu Items ............................................. 17-19
Adding and Removing Menus............................................................ 17-20
Using Menu Groups ........................................................................... 17-22
Summary ....................................................................................................... 17-26
Chapter 18................................................................................................................... 18-1
Application Design ....................................................................................................... 18-1

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

13

Introduction
Introduction ...................................................................................................... 18-2
Planning........................................................................................................... 18-2
Structured design............................................................................................. 18-3
Structured programming .................................................................................. 18-4
Object-oriented design..................................................................................... 18-5
Object-oriented programming .......................................................................... 18-5
Programming standards .................................................................................. 18-7
Variable naming ................................................................................... 18-7
Function naming .................................................................................. 18-8
Getting help ..................................................................................................... 18-8
Summary ....................................................................................................... 18-10
Appendix A .................................................................................................................... A-1
VB.NET Programming Standards.................................................................................. A-1
Why Programming Standards are Necessary ................................................... A-2
Setting Up Your Environment ............................................................................ A-3
Computer Setup..................................................................................... A-3
Option Strict ........................................................................................... A-4
Naming Conventions ......................................................................................... A-4
Naming Variables................................................................................... A-4
WebForm Control Naming Standards.................................................... A-7
WinForm Control Naming Standard....................................................... A-9
Naming ADO.NET Objects .................................................................. A-11
Coding Conventions ........................................................................................ A-12
Naming Data Structures....................................................................... A-12
Naming Procedures ............................................................................. A-14
Commenting Your Code ...................................................................... A-15
Indentation ........................................................................................... A-16
Summary ......................................................................................................... A-18
Appendix B .................................................................................................................... B-1
SQL Server Database Naming Standards..................................................................... B-1
Overview............................................................................................................ B-1
Database Naming Conventions ......................................................................... B-2
Table Naming .................................................................................................... B-2
Primary Key Definition ........................................................................... B-3
Common Columns ................................................................................. B-3
System Tables ................................................................................................... B-4
Temporary Tables.............................................................................................. B-4

14

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Introduction
Column Naming ................................................................................................. B-5
Field Prefix ............................................................................................. B-5
TimeStamp............................................................................................. B-6
Index Naming......................................................................................... B-6
Stored Procedure Naming ..................................................................... B-6
Trigger Naming ...................................................................................... B-7
View Naming.......................................................................................... B-7
Database Diagram Naming.................................................................... B-7
Default Naming ...................................................................................... B-7
Rule Naming .......................................................................................... B-8
Summary ........................................................................................................... B-8
Appendix C .................................................................................................................... C-1
PDSA Products & Services ........................................................................................... C-1
.NET Web Sites ................................................................................................. C-1
.NET Articles and White Papers ........................................................................ C-2
Advisor Magazine .................................................................................. C-2
Visual Studio Magazine ......................................................................... C-2
CoDe Magazine ..................................................................................... C-2
MSDN Online Whitepapers.................................................................... C-3
.NET Webcasts.................................................................................................. C-4
PDSA Newsletter ............................................................................................... C-5
.NET Books........................................................................................................ C-6
eBooks ................................................................................................... C-6
PDSA, Inc. Services .......................................................................................... C-7
PDSA, Inc. Products .......................................................................................... C-7
PDSA .NET Productivity Framework................................................... C-7
IT Manager's Toolkit............................................................................. C-11
More Details......................................................................................... C-12
PDSA, Inc. Training ......................................................................................... C-14

Introduction
This eBook is written for anyone who wants to learn how to become
a Visual Basic .NET programmer. Visual Basic is one of the most
VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

15

Introduction
widely used programming languages in the world. It is also one of
the easiest programming languages to learn, so it is a good choice
as a first language. Visual Basic.NET can create any type of .NET
application just like any other .NET language. In this course you will
be introduced to the VB.NET language.
This book is an excellent tutorial if you are considering moving from
a previous version of Visual Basic into the .NET Platform. You will
see that moving to VB.NET is not that hard, just an extension of what
you already know.

Goals of this eBook


By the end of this book you will have learned several very useful
techniques that will allow you to create a simple VB.NET application
and have a good foundation on which to continue on with more
advanced courses. You will learn the following in this course:

An overview of Visual Studio .NET

An introduction to the VB.NET language

Object Oriented Programming principles

Creating classes with methods and properties

Creating Windows Forms

Creating Web Forms

Basics of ADO.NET

Prerequisites
This eBook is designed for the beginning programmer or a Visual
Basic programmer who wishes to learn the VB.NET language. You
should already be familiar with the basics of programming and
working with the Windows 2000 operating system, Windows XP or
Windows Server 2003.

16

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

Technical Support

Assumptions
You will need some tools at your disposal so you can try out the
many exercises contained in this book. Below is a list of the tools
that you should have on your computer:

Microsoft Windows 2000, XP or Windows Server 2003

Microsoft .NET 2.0

Microsoft Visual Studio.NET 2005

Technical Support
Because of the complexity of .NET software development, PDSA,
Inc. does not provide free technical support related to the use of the
material in this eBook. Technical support is available for problems
with installation of the samples that are a part of this eBook but only
through email, please do not call.

Tip: It is strongly recommended that


you read this book thoroughly before
emailing us for technical support.

Installation
This eBook comes with an MSI file that you downloaded from the
web site. This MSI file will install all of the samples for this e-book.

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

17

Introduction

If you have Problems Installing the


Sample
Below is a list of suggestions to ensure your installation of the
sample files for the book is successful. Please read these carefully
and follow each one for best results.
1.

You must be running a supported ASP.NET operating system.


The only ones you can use are Windows 2000 Professional
with IIS installed, Windows 2000 Server or Advanced Server,
Windows XP Professional or Windows Server 2003.

2.

You must be running the final version of .NET 2.0 not a Beta
version.
a. Start Visual Studio .NET
b. Choose Help | About Microsoft Development Environment.
c. You should have the following Version numbers or later:
i. Microsoft Development Environment 2005 Version:
8.0.50727.42.
ii. Microsoft .NET Framework Version 2.0.50727

3.

You must have administrator rights for installation.

4.

IIS must be installed and running.

5.

Ensure that you can create an ASP.NET application using


VS.NET.

6.

Shut down VS.NET prior to doing the installation.

About Paul D. Sheriff


Paul is the CEO and President of PDSA, Inc., a Microsoft Partner, in
Southern California. PDSA, Inc. has provided customers with high
18

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

About Paul D. Sheriff


quality custom software, training, and architecture services since
1991.
Paul has been using .NET since Beta 1 and has written over 40
articles and 12 days of courseware on .NET. He has created many
videos on .NET programming and performed over 40 Webcasts for
Microsoft on .NET technology. Paul has lectured at various
conferences on .NET, including the launch of VS.NET at VSLive and
Microsoft Tech Ed 2003. Paul is the Microsoft Regional Director for
Southern California and helps run the local Developer Days event for
Microsoft as well as speaking at various local Microsoft events.
Paul has over twenty years experience architecting information
systems and his expertise is in much demand from companies such
as Microsoft, TransAmerica, Rockwell, American Express, J.D.
Powers & Associates and many others. Lately Paul has been helping
these companies architect .NET applications and helping them lay
out application frameworks such as the one presented in the eBook
Architecting ASP.NET Applications. This eBook may also be
purchased at www.pdsa.com/ebooks.
Over the years Paul has written over 150 articles for many different
publications. Paul is the author of the QUE book Paul Sheriff teaches
Visual Basic 6.0 and has co-authored the Addison-Wesley book
ASP.NET Developer's Jumpstart with Ken Getz. He has authored
over 7 eBooks as well on .NET and SharePoint technologies. Paul
speaks at many different conferences around the world including
Microsoft Tech-Ed, Advisor Live, VSLive, MSDN Events and
Microsoft Developer Days.
PDSA, Inc. is available for consulting work and on-site training in
Microsoft .NET, SharePoint, C#, Visual Basic, SQL Server and
Architecture. Contact PDSA, Inc. toll-free at (888) 899-PDSA (7372),
or (714) 734-9792. Fax (714) 734-9793. E-mail:
Psheriff@pdsa.com. VISIT THE PDSA WEB SITE at:
http://www.pdsa.com. See the Appendix for more information on
PDSA, Inc.

VB.NET Fundamentals
Copyright 2002-2006 by PDSA, Inc.
All rights reserved. Reproduction is strictly prohibited.

19

Anda mungkin juga menyukai