Microsoft Visual Basic 2008 Express Edition Build a Program Now Pelland
Microsoft Visual Basic 2008 Express Edition Build a Program Now Pelland
Microsoft Visual Basic 2008 Express Edition Build a Program Now Pelland
The document provides an overview of Visual Studio 2008. It discusses the different editions of Visual Studio including Express, Standard, Professional, and Team System editions. It also describes Visual Studio extensions and extensibility options, new features in Service Pack 1, resources for learning Visual Studio like code samples and videos, and tips for using Visual Studio like the task list, bookmarks, and error list.
The document provides information about the Vskills certification for Visual Basic 2005 Programmer. It assesses candidates on areas like the Visual Basic language, windows applications, web applications, files, databases, XML development and .NET platform services. The certification is intended for professionals, graduates and existing employees looking to prove their skills. It involves an online test of 50 multiple choice questions to be completed within 60 minutes, with passing marks of 25 out of 50.
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edi...waisfarjam
Ā
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edi...paboyjonesh32
Ā
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edi...samimylahji
Ā
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Programming Microsoft SQL Server 2000 with Microsoft Visual Basic NET 1st edition Edition Rick Dobson
Practice Area - Application Development - Selling To EnterpriseChetan Sharma
Ā
The document discusses application development, providing an overview of key programming languages like Java, Python, and JavaScript that are commonly used in web development, mobile apps, and software engineering. It also outlines common job roles in application development like web developers, mobile app developers, and back-end developers as well as the core skills required for these roles. Finally, the document discusses Microsoft products and certification tracks that are relevant for application development.
This document provides an introduction to Visual Basic 2008, including:
1. A brief description of Visual Basic 2008 and its evolution from earlier versions of BASIC. It is now a fully object-oriented programming language.
2. An overview of the Visual Basic 2008 Integrated Development Environment and how to create a new project.
3. Instructions for creating a simple first program to demonstrate adding two numbers and displaying the result in a message box.
Visual Studio 2008 provides tools for code editing, debugging, and building applications. It includes an integrated development environment with support for multiple programming languages like C#, VB, and C++. The IDE can be customized with a variety of settings and options. It also provides a project system to manage code components and references across one or more projects in a solution.
This document provides an overview of Visual Studio .NET 2005, including its various editions, new features, and system requirements. It discusses the Express, Standard, and Professional editions. Key new features include code snippets, refactoring tools, and improved debugging capabilities. The document also announces upcoming .NET events and links to additional information resources.
This document provides an overview of the software update architecture from the server side in System Center Configuration Manager. It discusses the key components like software update points, configuration items, and the synchronization process. It also covers concepts like multiple software update points, software update point failover, and the deployment of software update policies.
This document provides an overview of key features in Microsoft Visual Studio 2008 for developing smart client applications. Visual Studio 2008 improves developer productivity by providing tools for integrating UI design and development. It also enhances deployment through improved ClickOnce capabilities. Additionally, Visual Studio 2008 enables leveraging the Office 2007 UI style and using client application services.
The document discusses challenges developers face such as application performance issues, memory exceptions, and maintaining multiple builds. It describes how .NET features can help address these problems, including using performance counters to measure apps, NGEN to improve startup time, GC methods for memory management, CAS for security, and MSBuild to create a single build for multiple platforms. The presenter advocates using .NET solutions where possible rather than reinventing the wheel and highlights features in .NET 4.0.
Microsoft Visual Studio 2015 is an integrated development environment that allows developers to create applications from planning through deployment across many platforms. It includes tools for coding, debugging, testing and managing projects. Visual Studio supports languages like C#, C++, JavaScript and Visual Basic. It can be used to create applications for Windows, Android, iOS as well as web and cloud applications. Visual Studio integrates with Microsoft Team services and Team Foundation Server for source control and collaboration.
This document is an internship report submitted by Anup Kumar Singh to fulfill requirements for a bachelor's degree in computer science engineering. It details a summer internship completed at Microsoft Virtual Academy focused on learning and developing skills in C#. Key activities included taking online courses in C#, Windows app development, Visual Studio, and other Microsoft technologies. The report includes sections acknowledging contributions and outlining the scope, description, requirements, and activities undertaken during the internship.
This document summarizes the new features and improvements in Visual Studio 2010 SP1, including improved debugging capabilities, support for new technologies like Silverlight 4 and HTML5, and tools to improve developer productivity. It also outlines upcoming pre-release technologies like Visual Studio LightSwitch Beta 2 and ASP.NET MVC 3. A timeline is provided showing the release dates of Visual Studio 2010 RTM, SP1, and related feature packs.
This document provides an overview of Visual Studio 2012, Microsoft's integrated development environment. Some key points:
- Visual Studio 2012 allows developers to create applications for multiple platforms like Windows, Windows Phone, and Xbox. It also supports development for the web and cloud.
- The interface is streamlined for focus on development tasks. Productivity is enhanced through faster build times and improved debugging tools.
- Visual Studio supports an evolving software development model where other stakeholders are involved earlier. It facilitates capturing changing requirements.
- New platforms and app stores present challenges and opportunities for reaching new markets. Visual Studio aids in multi-platform development and publishing applications to stores.
This document provides an overview of Visual Studio 2012, Microsoft's integrated development environment. Some key points:
- Visual Studio 2012 allows developers to create applications for multiple platforms like Windows, Windows Phone, and Xbox. It also supports development for the web and cloud.
- The interface is streamlined for focus on development tasks. Productivity is enhanced through faster build times and improved debugging tools.
- Visual Studio supports an evolving software development model where other stakeholders are involved earlier. It facilitates capturing changing requirements.
- New platforms and app stores present challenges and opportunities for reaching new markets. Visual Studio aids in multi-platform development and publishing applications to stores.
Visual Studio 2012 provides tools for developing applications across many platforms. It includes support for Windows 8, web, cloud, and SharePoint development. The integrated development environment has been streamlined to improve productivity. Visual Studio works with Team Foundation Server to facilitate collaboration between developers and other stakeholders throughout the application lifecycle.
WordCampThessaloniki2011 Wordpress and Microsoft Web PlatformGeorge Kanellopoulos
Ā
This document summarizes how to use the popular blogging platform WordPress on the Microsoft Web Platform. Key points include:
- WordPress can be hosted on Windows using PHP and MySQL support in the Microsoft Web Platform.
- Plugins allow WordPress sites to leverage capabilities of the Microsoft Web Platform like SQL Server and Azure storage.
- Tools like WebPI and WebMatrix make it easy to install, manage, and publish WordPress sites on Windows.
- Additional Microsoft products and services provide capabilities to enhance WordPress sites hosted on Windows.
Wordcamp Thessaloniki 2011 Wordpress and Microsoft Web PlatformGeorge Kanellopoulos
Ā
This document summarizes how to use the popular blogging platform WordPress on the Microsoft Web Platform. Key points include:
- WordPress can be hosted on Windows using PHP and MySQL supported by the Microsoft Web Platform.
- Plugins allow WordPress sites to leverage capabilities of the Microsoft Web Platform like SQL Server and Azure storage.
- Tools like WebPI and WebMatrix make it easy to install, manage, and publish WordPress sites on Windows.
- Additional Microsoft products and services provide capabilities like theming, mobile apps, and free developer resources to enhance WordPress sites.
Everything You Ever Wanted To Know About Application CompatibilityStephen Rose
Ā
This document discusses various application compatibility solutions for migrating to Windows 7, including Application Virtualization (App-V), Microsoft Enterprise Desktop Virtualization (MED-V), and the Application Compatibility Toolkit (ACT). It provides an overview of each solution, how they work, their benefits, and how they can help address application compatibility challenges during a Windows 7 migration. App-V provides application isolation and streaming. MED-V creates a virtual Windows XP environment for applications not compatible with Windows 7. ACT helps identify and resolve application compatibility issues through shims and standard user analyzer.
This document summarizes Microsoft's efforts to support and contribute to open source software and PHP development. It discusses tools Microsoft has created to help PHP work well on Windows, such as FastCGI, IIS 7, PHP Manager, and a SQL Server driver for PHP. It also introduces WebMatrix, a new web development tool from Microsoft for creating and publishing PHP websites. The document aims to show Microsoft's desire to work with the open source community and provide positive contributions.
The document summarizes the features and capabilities of the Visual Studio 2010 and .NET Framework 4 Training Kit. It provides overviews of improvements to web development, parallel programming, cloud development, understanding and writing code, SharePoint development, Windows 7 development, Office business applications, and Visual Studio Team System 2010. The training kit includes presentations, hands-on labs, and demos to help users learn how to utilize Visual Studio 2010 features and .NET Framework 4 technologies.
Visual Studio is an integrated development environment from Microsoft used to develop applications for Windows, as well as web, Android, and iOS applications. It supports many programming languages and includes features like a code editor, debugger, and visual designers. Visual Studio editions include free Express editions suitable for smaller projects, and paid Professional, Premium, and Ultimate editions that offer additional tools and functionality for individual and professional developers.
World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...larencebapu132
Ā
This is short and accurate description of World war-1 (1914-18)
It can give you the perfect factual conceptual clarity on the great war
Regards Simanchala Sarab
Student of BABed(ITEP, Secondary stage)in History at Guru Nanak Dev University Amritsar Punjab šš
As of Mid to April Ending, I am building a new Reiki-Yoga Series. No worries, they are free workshops. So far, I have 3 presentations so its a gradual process. If interested visit: https://www.slideshare.net/YogaPrincess
https://ldmchapels.weebly.com
Blessings and Happy Spring. We are hitting Mid Season.
Ad
More Related Content
Similar to Microsoft Visual Basic 2008 Express Edition Build a Program Now Pelland (20)
This document provides an introduction to Visual Basic 2008, including:
1. A brief description of Visual Basic 2008 and its evolution from earlier versions of BASIC. It is now a fully object-oriented programming language.
2. An overview of the Visual Basic 2008 Integrated Development Environment and how to create a new project.
3. Instructions for creating a simple first program to demonstrate adding two numbers and displaying the result in a message box.
Visual Studio 2008 provides tools for code editing, debugging, and building applications. It includes an integrated development environment with support for multiple programming languages like C#, VB, and C++. The IDE can be customized with a variety of settings and options. It also provides a project system to manage code components and references across one or more projects in a solution.
This document provides an overview of Visual Studio .NET 2005, including its various editions, new features, and system requirements. It discusses the Express, Standard, and Professional editions. Key new features include code snippets, refactoring tools, and improved debugging capabilities. The document also announces upcoming .NET events and links to additional information resources.
This document provides an overview of the software update architecture from the server side in System Center Configuration Manager. It discusses the key components like software update points, configuration items, and the synchronization process. It also covers concepts like multiple software update points, software update point failover, and the deployment of software update policies.
This document provides an overview of key features in Microsoft Visual Studio 2008 for developing smart client applications. Visual Studio 2008 improves developer productivity by providing tools for integrating UI design and development. It also enhances deployment through improved ClickOnce capabilities. Additionally, Visual Studio 2008 enables leveraging the Office 2007 UI style and using client application services.
The document discusses challenges developers face such as application performance issues, memory exceptions, and maintaining multiple builds. It describes how .NET features can help address these problems, including using performance counters to measure apps, NGEN to improve startup time, GC methods for memory management, CAS for security, and MSBuild to create a single build for multiple platforms. The presenter advocates using .NET solutions where possible rather than reinventing the wheel and highlights features in .NET 4.0.
Microsoft Visual Studio 2015 is an integrated development environment that allows developers to create applications from planning through deployment across many platforms. It includes tools for coding, debugging, testing and managing projects. Visual Studio supports languages like C#, C++, JavaScript and Visual Basic. It can be used to create applications for Windows, Android, iOS as well as web and cloud applications. Visual Studio integrates with Microsoft Team services and Team Foundation Server for source control and collaboration.
This document is an internship report submitted by Anup Kumar Singh to fulfill requirements for a bachelor's degree in computer science engineering. It details a summer internship completed at Microsoft Virtual Academy focused on learning and developing skills in C#. Key activities included taking online courses in C#, Windows app development, Visual Studio, and other Microsoft technologies. The report includes sections acknowledging contributions and outlining the scope, description, requirements, and activities undertaken during the internship.
This document summarizes the new features and improvements in Visual Studio 2010 SP1, including improved debugging capabilities, support for new technologies like Silverlight 4 and HTML5, and tools to improve developer productivity. It also outlines upcoming pre-release technologies like Visual Studio LightSwitch Beta 2 and ASP.NET MVC 3. A timeline is provided showing the release dates of Visual Studio 2010 RTM, SP1, and related feature packs.
This document provides an overview of Visual Studio 2012, Microsoft's integrated development environment. Some key points:
- Visual Studio 2012 allows developers to create applications for multiple platforms like Windows, Windows Phone, and Xbox. It also supports development for the web and cloud.
- The interface is streamlined for focus on development tasks. Productivity is enhanced through faster build times and improved debugging tools.
- Visual Studio supports an evolving software development model where other stakeholders are involved earlier. It facilitates capturing changing requirements.
- New platforms and app stores present challenges and opportunities for reaching new markets. Visual Studio aids in multi-platform development and publishing applications to stores.
This document provides an overview of Visual Studio 2012, Microsoft's integrated development environment. Some key points:
- Visual Studio 2012 allows developers to create applications for multiple platforms like Windows, Windows Phone, and Xbox. It also supports development for the web and cloud.
- The interface is streamlined for focus on development tasks. Productivity is enhanced through faster build times and improved debugging tools.
- Visual Studio supports an evolving software development model where other stakeholders are involved earlier. It facilitates capturing changing requirements.
- New platforms and app stores present challenges and opportunities for reaching new markets. Visual Studio aids in multi-platform development and publishing applications to stores.
Visual Studio 2012 provides tools for developing applications across many platforms. It includes support for Windows 8, web, cloud, and SharePoint development. The integrated development environment has been streamlined to improve productivity. Visual Studio works with Team Foundation Server to facilitate collaboration between developers and other stakeholders throughout the application lifecycle.
WordCampThessaloniki2011 Wordpress and Microsoft Web PlatformGeorge Kanellopoulos
Ā
This document summarizes how to use the popular blogging platform WordPress on the Microsoft Web Platform. Key points include:
- WordPress can be hosted on Windows using PHP and MySQL support in the Microsoft Web Platform.
- Plugins allow WordPress sites to leverage capabilities of the Microsoft Web Platform like SQL Server and Azure storage.
- Tools like WebPI and WebMatrix make it easy to install, manage, and publish WordPress sites on Windows.
- Additional Microsoft products and services provide capabilities to enhance WordPress sites hosted on Windows.
Wordcamp Thessaloniki 2011 Wordpress and Microsoft Web PlatformGeorge Kanellopoulos
Ā
This document summarizes how to use the popular blogging platform WordPress on the Microsoft Web Platform. Key points include:
- WordPress can be hosted on Windows using PHP and MySQL supported by the Microsoft Web Platform.
- Plugins allow WordPress sites to leverage capabilities of the Microsoft Web Platform like SQL Server and Azure storage.
- Tools like WebPI and WebMatrix make it easy to install, manage, and publish WordPress sites on Windows.
- Additional Microsoft products and services provide capabilities like theming, mobile apps, and free developer resources to enhance WordPress sites.
Everything You Ever Wanted To Know About Application CompatibilityStephen Rose
Ā
This document discusses various application compatibility solutions for migrating to Windows 7, including Application Virtualization (App-V), Microsoft Enterprise Desktop Virtualization (MED-V), and the Application Compatibility Toolkit (ACT). It provides an overview of each solution, how they work, their benefits, and how they can help address application compatibility challenges during a Windows 7 migration. App-V provides application isolation and streaming. MED-V creates a virtual Windows XP environment for applications not compatible with Windows 7. ACT helps identify and resolve application compatibility issues through shims and standard user analyzer.
This document summarizes Microsoft's efforts to support and contribute to open source software and PHP development. It discusses tools Microsoft has created to help PHP work well on Windows, such as FastCGI, IIS 7, PHP Manager, and a SQL Server driver for PHP. It also introduces WebMatrix, a new web development tool from Microsoft for creating and publishing PHP websites. The document aims to show Microsoft's desire to work with the open source community and provide positive contributions.
The document summarizes the features and capabilities of the Visual Studio 2010 and .NET Framework 4 Training Kit. It provides overviews of improvements to web development, parallel programming, cloud development, understanding and writing code, SharePoint development, Windows 7 development, Office business applications, and Visual Studio Team System 2010. The training kit includes presentations, hands-on labs, and demos to help users learn how to utilize Visual Studio 2010 features and .NET Framework 4 technologies.
Visual Studio is an integrated development environment from Microsoft used to develop applications for Windows, as well as web, Android, and iOS applications. It supports many programming languages and includes features like a code editor, debugger, and visual designers. Visual Studio editions include free Express editions suitable for smaller projects, and paid Professional, Premium, and Ultimate editions that offer additional tools and functionality for individual and professional developers.
World war-1(Causes & impacts at a glance) PPT by Simanchala Sarab(BABed,sem-4...larencebapu132
Ā
This is short and accurate description of World war-1 (1914-18)
It can give you the perfect factual conceptual clarity on the great war
Regards Simanchala Sarab
Student of BABed(ITEP, Secondary stage)in History at Guru Nanak Dev University Amritsar Punjab šš
As of Mid to April Ending, I am building a new Reiki-Yoga Series. No worries, they are free workshops. So far, I have 3 presentations so its a gradual process. If interested visit: https://www.slideshare.net/YogaPrincess
https://ldmchapels.weebly.com
Blessings and Happy Spring. We are hitting Mid Season.
INTRO TO STATISTICS
INTRO TO SPSS INTERFACE
CLEANING MULTIPLE CHOICE RESPONSE DATA WITH EXCEL
ANALYZING MULTIPLE CHOICE RESPONSE DATA
INTERPRETATION
Q & A SESSION
PRACTICAL HANDS-ON ACTIVITY
Understanding PāN Junction Semiconductors: A Beginnerās GuideGS Virdi
Ā
Dive into the fundamentals of PāN junctions, the heart of every diode and semiconductor device. In this concise presentation, Dr. G.S. Virdi (Former Chief Scientist, CSIR-CEERI Pilani) covers:
What Is a PāN Junction? Learn how P-type and N-type materials join to create a diode.
Depletion Region & Biasing: See how forward and reverse bias shape the voltageācurrent behavior.
VāI Characteristics: Understand the curve that defines diode operation.
Real-World Uses: Discover common applications in rectifiers, signal clipping, and more.
Ideal for electronics students, hobbyists, and engineers seeking a clear, practical introduction to PāN junction semiconductors.
GDGLSPGCOER - Git and GitHub Workshop.pptxazeenhodekar
Ā
This presentation covers the fundamentals of Git and version control in a practical, beginner-friendly way. Learn key commands, the Git data model, commit workflows, and how to collaborate effectively using Git ā all explained with visuals, examples, and relatable humor.
A measles outbreak originating in West Texas has been linked to confirmed cases in New Mexico, with additional cases reported in Oklahoma and Kansas. The current case count is 817 from Texas, New Mexico, Oklahoma, and Kansas. 97 individuals have required hospitalization, and 3 deaths, 2 children in Texas and one adult in New Mexico. These fatalities mark the first measles-related deaths in the United States since 2015 and the first pediatric measles death since 2003.
The YSPH Virtual Medical Operations Center Briefs (VMOC) were created as a service-learning project by faculty and graduate students at the Yale School of Public Health in response to the 2010 Haiti Earthquake. Each year, the VMOC Briefs are produced by students enrolled in Environmental Health Science Course 581 - Public Health Emergencies: Disaster Planning and Response. These briefs compile diverse information sources ā including status reports, maps, news articles, and web contentā into a single, easily digestible document that can be widely shared and used interactively. Key features of this report include:
- Comprehensive Overview: Provides situation updates, maps, relevant news, and web resources.
- Accessibility: Designed for easy reading, wide distribution, and interactive use.
- Collaboration: The āunlocked" format enables other responders to share, copy, and adapt seamlessly. The students learn by doing, quickly discovering how and where to find critical information and presenting it in an easily understood manner.
āCURRENT CASE COUNT: 817 (As of 05/3/2025)
⢠Texas: 688 (+20)(62% of these cases are in Gaines County).
⢠New Mexico: 67 (+1 )(92.4% of the cases are from Eddy County)
⢠Oklahoma: 16 (+1)
⢠Kansas: 46 (32% of the cases are from Gray County)
HOSPITALIZATIONS: 97 (+2)
⢠Texas: 89 (+2) - This is 13.02% of all TX cases.
⢠New Mexico: 7 - This is 10.6% of all NM cases.
⢠Kansas: 1 - This is 2.7% of all KS cases.
DEATHS: 3
⢠Texas: 2 ā This is 0.31% of all cases
⢠New Mexico: 1 ā This is 1.54% of all cases
US NATIONAL CASE COUNT: 967 (Confirmed and suspected):
INTERNATIONAL SPREAD (As of 4/2/2025)
⢠Mexico ā 865 (+58)
āChihuahua, Mexico: 844 (+58) cases, 3 hospitalizations, 1 fatality
⢠Canada: 1531 (+270) (This reflects Ontario's Outbreak, which began 11/24)
āOntario, Canada ā 1243 (+223) cases, 84 hospitalizations.
⢠Europe: 6,814
How to manage Multiple Warehouses for multiple floors in odoo point of saleCeline George
Ā
The need for multiple warehouses and effective inventory management is crucial for companies aiming to optimize their operations, enhance customer satisfaction, and maintain a competitive edge.
How to Set warnings for invoicing specific customers in odooCeline George
Ā
Odoo 16 offers a powerful platform for managing sales documents and invoicing efficiently. One of its standout features is the ability to set warnings and block messages for specific customers during the invoicing process.
How to Customize Your Financial Reports & Tax Reports With Odoo 17 AccountingCeline George
Ā
The Accounting module in Odoo 17 is a complete tool designed to manage all financial aspects of a business. Odoo offers a comprehensive set of tools for generating financial and tax reports, which are crucial for managing a company's finances and ensuring compliance with tax regulations.
Odoo Inventory Rules and Routes v17 - Odoo SlidesCeline George
Ā
Odoo's inventory management system is highly flexible and powerful, allowing businesses to efficiently manage their stock operations through the use of Rules and Routes.
Multi-currency in odoo accounting and Update exchange rates automatically in ...Celine George
Ā
Most business transactions use the currencies of several countries for financial operations. For global transactions, multi-currency management is essential for enabling international trade.
Microsoft Visual Basic 2008 Express Edition Build a Program Now Pelland
1. Visit https://ebookultra.com to download the full version and
explore more ebooks
Microsoft Visual Basic 2008 Express Edition
Build a Program Now Pelland
_____ Click the link below to download _____
https://ebookultra.com/download/microsoft-visual-
basic-2008-express-edition-build-a-program-now-pelland/
Explore and download more ebooks at ebookultra.com
2. Here are some suggested products you might be interested in.
Click the link to download
Mastering Microsoft Visual Basic 2008 Evangelos Petroutsos
https://ebookultra.com/download/mastering-microsoft-visual-
basic-2008-evangelos-petroutsos/
Visual Basic 2008 Programmer s Reference Rod Stephens
https://ebookultra.com/download/visual-basic-2008-programmer-s-
reference-rod-stephens/
Visual Basic 2008 Recipes A Problem Solution Approach 1st
Edition Rakesh Rajan
https://ebookultra.com/download/visual-basic-2008-recipes-a-problem-
solution-approach-1st-edition-rakesh-rajan/
Programming Microsoft Visual Basic NET Version 2003
Francesco Balena
https://ebookultra.com/download/programming-microsoft-visual-basic-
net-version-2003-francesco-balena/
3. Programming with Microsoft Visual Basic 2012 6th Edition
Diane Zak
https://ebookultra.com/download/programming-with-microsoft-visual-
basic-2012-6th-edition-diane-zak/
Programming Microsoft SQL Server 2000 with Microsoft
Visual Basic NET 1st edition Edition Rick Dobson
https://ebookultra.com/download/programming-microsoft-sql-
server-2000-with-microsoft-visual-basic-net-1st-edition-edition-rick-
dobson/
An introduction to programming using Visual Basic 2008
with Visual Studio Expression edition DVD Schneider
https://ebookultra.com/download/an-introduction-to-programming-using-
visual-basic-2008-with-visual-studio-expression-edition-dvd-schneider/
Sams Teach Yourself Microsoft Visual Basic NET 2003 in 21
Days 2nd Edition Steven Holzner
https://ebookultra.com/download/sams-teach-yourself-microsoft-visual-
basic-net-2003-in-21-days-2nd-edition-steven-holzner/
Microsoft Visual Basic Programs to Accompany Programming
Logic and Design 3rd Edition Jo Ann Smith
https://ebookultra.com/download/microsoft-visual-basic-programs-to-
accompany-programming-logic-and-design-3rd-edition-jo-ann-smith/
5. Microsoft Visual Basic 2008 Express Edition Build a
Program Now Pelland Digital Instant Download
Author(s): Pelland, Patrice
ISBN(s): 9788120335042, 0735625417
Edition: PAP/CDR
File Details: PDF, 7.29 MB
Year: 2008
Language: english
8. iii
Contents iii
Chapter 1
Introducing Microsoft Visual Basic 2008
Express Edition 1
What Is .NET? 2
What Is Visual Basic 2008? 4
Is Visual Basic 2008 an Object-Oriented
Programming Language? 4
What Is Visual Basic 2008 Express Edition? 9
What Kinds of Applications Can You Build with
Visual Basic 2008 Express Edition? 10
What Are the Key Features You Need to Know
About? 11
Chapter 2
Installing Visual Basic 2008 Express Edition 15
Preparing to Install Visual Basic 2008 Express Edition 16
Side-by-Side Installation 16
Prerelease Versions of Visual Basic 2008 Express Edition 17
Installing Visual Basic 2008 Express Edition 17
Chapter 3
Creating Your First Applications 25
Three Types of Applications: What Are the Differences? 26
Getting Started with the IDE 28
Building the Projects 31
Building a Console Application 31
Getting to Know Solution Explorer 32
Getting Help: Microsoft Visual Studio 2008
Express Edition Documentation 34
Coding Your Console Application 37
Customizing the IDE 39
Creating a Windows Application 41
Chapter 4
Creating Your Own Web Browser in Less
Than Five Minutes 47
What Is a Project? 48
What Is the Design Layout? 49
To Create a Simple Web Browser 50
Putting It All Together 56
Chapter 5
Using Rapid Application Development Tools
with Visual Basic 2008 59
Snapping and Aligning Controls Using Snap Lines 60
Using IntelliSenseāYour New Best Friend! 62
Using IntelliSense as You Go 62
Using IntelliSense Filtering: Removing the āUncommonā 63
Opening IntelliSense: Pressing Ctrl+Spacebar 64
Opening IntelliSense: Typing a Period or Left Parenthesis 64
Using IntelliSense Code Snippets: The Time-Saver 66
Invoking IntelliSense Code Snippets 67
Exploring Real-Time Error Detection and Correction 68
Oh, My...My Is Great 70
Contents
9. iv Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
Renaming 72
Why Should You Rename? 73
How to Use the Rename Feature 73
Exploring Common Windows Controls 75
What Happens When an Event Is Triggered? 78
Chapter 6
Modifying Your Web Browser 85
Opening Your Application 86
Interacting Through Dialog Boxes 93
Adding an About Dialog Box 93
Adding a Navigate Dialog Box 96
Having a Professional Look and Feel
at Your Fingertips 99
Adding a Tool Strip Container and Some Tools 99
Adding a Status Bar to Your Browser 101
Personalizing Your Application with Windows Icons 104
Redoing the Browser 112
Windows Presentation Foundation 112
WPF and XAML 113
Chapter 7
Fixing the Broken Blocks 125
Debugging an Application 126
Using a DLL in an Application 126
Using Breakpoints, Locals, Edit and Continue, and
Visualizers 128
Chapter 8
Managing the Data 141
What Is a Database? 142
Whatās in a Database? 142
What Are Data Normalization and Data Integrity? 143
What Is Null? 145
What Are Primary Keys and Foreign Keys? 146
How Do You Interact with a Relational Database? 148
Using SQL Server 2005 Express Edition in
Visual Basic 2008 Express Edition 150
Creating a Database Using Visual Basic 2008
Express Edition 151
Creating Tables in Your Database 153
Creating Relationships Between the Tables 155
Entering Data in SQL Server Tables Using
Visual Studio 159
What Are ADO.NET, Data Binding, and LINQ? 163
Developing the CarTracker Application 165
Using the Component Tray 172
How Do I Get More Meaningful Information
on My Form? 173
Using LINQ 182
Chapter 9
Building Your Own Weather Tracker Application 187
Exploring the Features of the Weather Tracker
Application 188
Creating the Application User Interface 189
Adding Notification Area Capabilities 191
Adding the Splash Screen and About Dialog Box 199
Adding the Options Dialog Box 202
Using the MSN Weather Web Service 204
Connecting to MSN Weather Web Services 206
Setting User and Application Preferences 210
Working in the Background 211
Completing the Core Weather Tracker Functionality 219
Testing Weather Tracker 225
Working with the Options Dialog Box 226
Testing Weather Tracker Options 229
And Now, Just ClickOnce 229
Glossary 235
Index 237
10. v
Introduction
Microsoft Visual Basic 2008 Express Edition (and the
other Visual Studio 2008 Express Edition products) is, in my
opinion, one of the best and most intelligent ideas to come
from the Developer Division at Microsoft. Iām applauding
and cheering for the people who had this brilliant idea
because I believe there is a real need and demand for a
world-class, powerful product for hobbyist programmers,
students, and professional developers. And Visual Basic
2008 Express Edition provides all of that and more.
Visual Basic 2008 Express Edition is a fully functional
subset of Visual Studio 2008, suitable for creating and
maintaining Windows applications and libraries. Itās not
a timed-bomb edition, a demo, or a feature-limited
versionāno, itās a key Microsoft initiative to reach more
people and give them the ability to have fun while creating
cool software.
Who Is This Book For?
This book is for everybody: students, hobbyist pro-
grammers, and people who always thought programming
was a tough task. Itās for people who have ideas like āI wish
I could build a tool to store all my recipes and then print
them and send them to my friends,ā āI wish I could build
this cool card game that I have never found elsewhere,ā āI
wish I could build this cool software to store my DVD and
CD collection,ā āI wish I could build this software to help me
work with matrices and plot graphics for my math class,ā
and many more projects that you can imagine!
This book is for people who have ideas but donāt know
how to bring them to reality. And itās a good introduction
to the art and science of developing software.
How This Book Is Organized
This book consists of nine chapters, each covering a
particular feature or technology about Visual Basic 2008
Express Edition. Most chapters build on previous chapters,
so you should plan on reading the material sequentially.
Conventions and Features in This Book
This book presents information using conventions
designed to make the information readable and easy to
follow. Before you start the book, read the following list,
which explains conventions youāll see throughout the book
and points out helpful features in the book that you might
want to use:
Each exercise is a series of tasks. Each task is presented
ā
as a series of numbered steps (step 1, 2, and so on).
Each exercise is preceded by a procedural heading that
lets you know what you will accomplish in the exercise.
Introduction v
11. vi Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
Boxes labeled
ā TIP, NOTE, MORE INFO, and so on, pro-
vide additional information or alternative methods for
completing a step successfully.
Boxes labeled
ā CAUTION alert you to information you
need to verify before continuing.
Text that you type appears in bold.
ā
Menu commands, dialog box titles, and other user
ā
interface elements appear with each word capitalized,
such as in āclick Save As.ā
A plus sign (+) between two key names means that you
ā
must press those keys at the same time. For example,
āPress Alt+Tabā means that you hold down the Alt key
while you press the Tab key.
Code listings appear in a monospaced font in this book.
ā
Sidebars throughout the book provide more in-depth
ā
information about the content. The sidebars might con-
tain background information, design tips, or features
related to the information being discussed.
Each chapter ends with an āIn Summaryā¦ā section that
ā
briefly reviews what you learned in the current chapter
and previews what the next chapter will present.
System Requirements
Youāll need the following hardware and software to
complete the exercises in this book:
Windows Vista, Microsoft Windows XP with Service
ā
Pack 2, or Microsoft Windows Server 2003 with
Service Pack 2
Visual Basic 2008 Express Edition
ā
1 GHz 32-bit (x86) processor
ā
1 GB MB RAM (512 MB minimum)
ā
40 GB hard drive with at least 15 GB of available space
ā
Support for Super VGA graphics (for support for
ā
DirectX 9 graphics, see the recommended requirements
at www.microsoft.com/windows/products/windowsvista/
editions/systemrequirements.mspx)
CD-ROM or DVD-ROM drive
ā
Microsoft mouse or compatible pointing device
ā
Youāll also need administrator access to your computer
to configure SQL Server 2005 Express Edition.
Code Samples
You can download the code samples for the examples
in this book from the bookās companion content page at
the following address: http://www.microsoft.com/mspress/
companion/9780735625419/. Youāll use the code samples
and starter solutions as you perform the exercises in the
book. By using the code samples, you wonāt waste time cre-
ating files that arenāt relevant to the exercise. The files and
step-by-step instructions also let you learn by doing, which
is an effective way to acquire and remember new skills.
Youāll also find the complete solutions if you want to verify
your work or simply want to look at them.
N O T E
The companion DVD contains the Visual Basic 2008 Express Edition soft-
ware needed to complete the exercises in this book. The DVD also includes
the other Visual Studio 2008 Express Editionsāfor Visual C#, Visual C++,
and Web development. You can install any of the Express Edition products
included on the DVD. See Chapter 2, āInstalling Visual Basic 2008 Express
Edition,ā for detailed installation instructions.
12. vii
Introduction vii
Installing the Code Samples
Follow these steps to install the code samples on your
computer.
1. Download the code samples from http://www.microsoft.
com/mspress/companion/9780735625419/.
2. After you download the code samples file, run the
installer.
3. Follow the instructions that appear.
The code samples are installed in the Documents
Microsoft PressVB 2008 Express folder on your
computer.
Using the Code Samples
Each chapter in this book explains when and how to use
any code samples for that chapter. When itās time to use a
code sample, the book will list the instructions for how to
open the files. The chapters are built around scenarios that
simulate real programming projects so you can easily apply
the skills you learn to your own work.
For those of you who like to know all the details, a list
of the code sample projects appears in the following table.
Almost all projects have solutions available for the practice
exercises. The solutions for each project are included in the
folder for each chapter and are labeled āComplete.ā
Project Description
Chapters 1 and 2 No sample projects.
Chapter 3
MyFirstConsoleApplication
MyFirstWindowsApplication
Application that takes two numbers, adds them together, and then displays the sum in a
console window.
Same application as MyFirstConsoleApplication, but this one displays the result in a
message box.
Chapter 4
MyOwnBrowser
Simple Web browser application that enables the user to browse on the Internet.
Chapter 5
TestProject
Application that teaches you to use the most important features in Visual Basic 2008
Express Edition.
Chapter 6
MyOwnBrowser
This is the same application you developed in Chapter 4, enhanced with additional
features. Youāll add menus, toolbars, status and progress bars, and a navigation win-
dow with autocomplete. Youāll also build a simple browser using Windows Presentation
Foundation (WPF).
13. viii Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
Uninstalling the Code Samples
Follow these steps to remove the code samples from
your computer.
ON WINDOWS VISTA
1. In Control Panel, click Programs.
2. Under Programs and Features, click Uninstall a Program.
3. In the list of programs, select Microsoft Visual Basic
2008 Express Edition: Build a Program Now!, and then
click Uninstall.
4. Follow the instructions on the screen to remove the
code samples.
ON WINDOWS XP
1. In Control Panel, open Add or Remove Programs.
2. From the Currently Installed Programs list, select Micro-
soft Visual Basic 2008 Express Edition: Build a Program
Now!, and click Remove.
3. Follow the instructions on the screen to remove the
code samples.
Prerelease Software
This book was reviewed and tested against the Novem-
ber 2007 release candidate for Visual Studio 2008. This book
is expected to be fully compatible with the final release of
Visual Studio 2008. If there are any changes or corrections
for this book, theyāll be collected and added to a Microsoft
Knowledge Base article. See the āSupport for This Bookā
section later in this introduction for more information.
Technology Updates
As technologies related to this book are updated, links
to additional information will be added to the Microsoft
Project Description
Chapter 7
Debugger
An application full of problems to help you learn how to debug an application by using
features of Visual Basic 2008 Express Edition.
Chapter 8
CarTracker
An application enabling the user to track car ads from the Internet using a SQL Server
2005 Express database to store the information. Youāll also be introduced to Language
Integrated Query (LINQ).
Chapter 9
Weather Tracker
An application that runs in the system tray and has a nice user interface to display
weather data collected by your application from the MSN Weather service. Youāll also
create a deployment package for the distribution of your application.
16. 1 1
What Is .NET?, 2
What Is Visual Basic
2008?, 4
Is Visual Basic 2008
an Object-Oriented
Programming
Language?, 4
What Is Visual Basic 2008
Express Edition?, 9
Chapter 1
Introducing Microsoft
Visual Basic 2008
Express Edition
Maybe youāve decided to try programming and find yourself with this
book. If thatās the case, youāve come to the right place. This book is all about
introducing you to the art, science, and joys of creating software for Micro-
soft Windowsāyes, the same Microsoft Windows you probably use every
day. Throughout the book, Iāll show you how to build applications that are
similar to many of the applications you use on a regular basis, such as your
Internet browser, your word processor, your e-mail software, and your per-
sonal finance application. Youāre probably wondering how you could pos-
sibly do this with no programming experience. Donāt worry. By the time you
finish this book, youāll be a believer. Weāll have a blast, and because youāll
actually be building applications as you follow along with each exercise,
youāll see for yourself just how easy it can be.
17. 2 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
What is this .NET thing everybody is talking about? Maybe youāve seen the term some-
where online or have come across it in the jobs section of your Sunday newspaper. A good
analogy is that .NETāalso called the .NET Frameworkāis to a software developer what tools
and manuals are to an auto mechanic.
Here is a formal definition of the .NET Framework:
The .NET Framework is a platform with which you can develop software applications
and libraries called managed applications; it provides you with the compiler and tools
you need to build, debug, and execute managed applications.
For our purposes, you could say that .NET is the platform that gives you everything you
need to develop and run managed applications that run on Windows.
We say that applications are managed because their execution is managed by the .NET
Framework. In fact, the .NET Framework manages the execution by providing a controlled
runtime environment that offers a wide variety of services, such as loading your applications,
managing memory, and monitoring and maintaining security and integrity while the applica-
tion runs. Before .NET (and Java), applications were unmanaged because they were not
executed by a controlled runtime environment. No other component of the operating
system provides the services .NET offers. The applications had to manage their own services,
which sometimes led to erroneous code, security holes, and data corruption. Because of
these problems, applications were tough to maintain and debug.
The .NET Framework provides you with a wide variety of tools, such as compilers, debug-
gers, programming languages, an execution engine (named the Common Language Runtime
[CLR]), developer tools, and a large number of predefined ābuilding blockā libraries. These
libraries are named Framework Class Libraries (FCLs). You can think of each .NET component
as a building block in a house and each version of .NET as an insulation layer in the walls of
a house. Figure 1-1 illustrates how many versions of .NET are on the market, as well as what
components have been added and in which version they belong.
What Is .NET?
N O T E
Throughout this book, Iāll use
the terms framework and .NET
Framework synonymously.
18. Chapter 1: Introducing Microsoft Visual Basic 2008 Express Edition 3
NET 2.
0
NET 3.0
NET 3.5
WCF
WF
WPF
CardSpace
LINQ
AJAX
REST
CLR
WinForms
Web Services
ASP.NET
Visual Studio 2008
Figure 1-1
Additive versions of the .NET Framework
Some of these building blocks ship with the Windows Vista operating system. Two
popular ones are Windows Presentation Foundation (WPF) and Windows Communication
Foundation (WCF). WPF is a library that helps you build richer user interfaces and Windows
Vistaālike applications for Windows. WCF, as its name implies, is a library that helps two
applications talk to each other using messages. To understand the relationship between
.NET 3.0 and .NET 3.5, remember that .NET 3.0 comes with Windows Vista and .NET 3.5
comes with Visual Studio 2008. Language Integrated Query (LINQ), which simplifies writing
code that manipulates data from various data sources (SQL Server databases, XML files, and
so on), is one of the features in .NET 3.5 that weāll cover in this book.
N O T E
What do the other abbreviations
and names in Figure 1-1 mean?
WF is the Windows Workflow
Foundation, another building
block that developers can use to
help automate business processes
through programs. CardSpace is
a technology related to manag-
ing online identitiesāsomething
like using a credit card. AJAX
(Asynchronous JavaScript
And XML) is used to develop
Web applications, and REST
(Representational State Transfer)
is a programming architecture
used for transferring data on
the Web.
19. 4 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
I wonāt put you to sleep with all the definitions for each building block. Weāre going to
use or talk about most of them in our projects in this book, and Iāll introduce the blocks
when appropriate. Just consider Figure 1-1 and return to it when you need to do so.
Two notes about this figure are worth mentioning.
First, look at the blue component on top of the concentric circles. Microsoft Visual Studio
2008 is not part of the .NET Framework, but it touches the .NET Framework at all levels. With
Visual Studio 2008, you can develop applications that take advantage of all the components
of the .NET Framework.
Second, notice that the CLR, among other components, is at the center of the circles. The
CLR is a crucial part of the foundation because itās the engine that loads and manages the
execution of source code.
Visual Basic 2008 is one of the programming languages that target the .NET Framework.
Like any spoken or written language, Visual Basic has syntax rules and a series of valid words
you can use to create your applications. Visual Basic is a popular choice for beginners because
some people find the syntax simpler than the syntax of many other programming languages.
If you have used an older version of Visual Basic (such as Visual Basic 4.0, 5.0, or 6.0), youāll
find some familiar constructs and a familiar user interface (UI) in Visual Basic 2008.
Visual Basic 2008 is a fully fledged object-oriented programming language. Letās talk
about what this means.
I M P O R TA N T
Itās not necessary to have
Visual Studio to develop .NET
applications, but using it offers
many advantages, as youāll see in
this book.
I M P O R TA N T
The CLR hasnāt changed in
Windows Vista and Visual
Studio 2008; the CLR that is run-
ning on all operating systems is
.NET 2.0.
What Is Visual Basic 2008?
Is Visual Basic 2008 an Object-Oriented
Programming Language?
20. Chapter 1: Introducing Microsoft Visual Basic 2008 Express Edition 5
Object-oriented programming (OOP) is a programming style (or programming para-
digm). There are other programming paradigms, such as functional or procedural program-
ming. Languages such as C, Fortran, Pascal, and previous versions of Visual Basic all use
functional or procedural programming paradigms. These paradigms focus more on the
actions, while OOP focuses more on the data itself.
Applications that use the OOP paradigm are developed using OOP languages (OOPLs).
The first OOPLs were introduced in the late 1960s, but they really became popular in the late
1970s. They are widely used today because most people agree that theyāre easy to learn, use,
debug, and maintain. For instance, OOPLs easily represent real-world objects. Visual Basic
2008 is an OOPL as are C#, C++, Java, Smalltalk, Lisp, and others.
Programmers use OOP to write programs that represent the decomposition of real-
world problems into modules. Those modules represent real-world objects and are known as
classes or types. You can think of an OOP program as a collection of objects interacting with
each other. Using OOP, a programmer defines new types to represent real-world objects,
such as a plane, a person, a customer, a dog, or a car. Those types or classes have what are
known as constructors, which developers use to create objects or instances. An object in a
program is a unit that represents one instance of a real-world object. Itās a self-contained
unit because it includes all the data and functionality associated with that object. This means
each object created in an application contains all the information that characterizes it (data
members or fields) and all the actions (methods) that can access or modify that information.
Here is a simple example in Visual Basic 2008 that defines a Person class:
1 Public Class Person
2 āData members
3 Private Name As String
4 Private Address As String
5 Private City As String
6 Private State As String
7 Private ZIP As String
8 Private Country As String
9
10 āMethods
11 Overridable Sub Display()
12 Console.WriteLine(Name)
13 Console.WriteLine(Address)
14 Console.WriteLine(City)
M O R E I N F O
With C++ you can develop proce-
dural applications, pure object-
oriented applications, or a mix
of both.
21. 6 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
15 Console.WriteLine(State)
16 Console.WriteLine(ZIP)
17 Console.WriteLine(Country)
18 End Sub
19 End Class
This class includes private data members and a Display method to print the objectās
content to the console. The Sub method is by default public. The Overridable keyword means
that a new class derived from this class will be able to write its own implementation of the
Display method.
Letās use a different example to go over these concepts some more. My dog, Chopin,
is an instance of the class Dog, and the class Dog is a subclass of the Animal class. Because
Chopin is a dog, he has some behaviors and data that are proper for a dog. But because a
dog is also an animal, Chopin also inherits some data and behaviors from the Animal class.
This means that the instance Chopin of the class Dog has data members that character-
ize him and methods that I can call on that little furry ball. For example, here is the instance
information for the Chopin object:
Data
Breed
ā Heās a Maltese.
Gender
ā Heās male.
Weight
ā His weight is 5.5 pounds (2.5 kilograms).
Color
ā Heās white.
Name
ā His name is Chopin Chabispel.
Age
ā Heās three years old.
Actions
He speaks (barks).
ā
He eats.
ā
He moves.
ā
He sleeps.
ā
M O R E I N F O
In the example of the Person
class, you would need to imple-
ment properties to access or
modify the Private fields from
outside the class. These types of
fields hide data in your class.
22. Chapter 1: Introducing Microsoft Visual Basic 2008 Express Edition 7
All these data items (breed, gender, weight, color, name, and age) and actions (speak,
eat, move, and sleep) characterize him, but they can also characterize any other dog, such as
my neighborās dog, Molly. And if you think about it, those items can characterize any animal.
This means that the class Dog inherits data members and methods from the class Animal.
Letās say you want to develop an application for a veterinary clinic. To cover the cats
who come to your clinic, all you must do is create a Cat class that also inherits from the class
Animal. Then each class (Cat and Dog) could override functionality in the Animal class as
needed. For instance, for the Cat class the Speak method would be meows instead of barks.
This means that those Speak methods for Cat and Dog are specializations of the regular
animal Speak method.
Letās look at the Person class example again. This time, Iāll also show an Employee class
that derives from the Person class. The Employee class derives from the Person class by using
the keyword Inherits followed by the Person element. The keyword Overrides changes the
implementation of the Display method.
20 Public Class Employee
21 Inherits Person
22
23 Public Level As Integer
24 Public Salary As Integer
25
26 Overrides Sub Display()
27 Console.WriteLine(Name + ā is at level ā + Level.ToString() +
ā and has a salary of : ā + Salary.ToString() + ā$ā)
28 Console.WriteLine(āHis address is:ā)
29 Console.WriteLine(Address)
30 Console.WriteLine(City + ā,ā + State + ā ā + ZIP)
31 Console.WriteLine(Country)
32 End Sub
33 End Class
In this case, the Employee class inherits from the Person class and therefore gets all the
data fields from that base class. The Employee class doesnāt have to redefine any of the fields
in its definition because it gets them automatically from Person. So, for the Employee class,
you must specify only what is different from an instance of the Person class. For example, an
instance of the Employee class would have Level and Salary, whereas none of the instances
T I P
In this book, youāll notice that
some code listings include line
numbers. If a line does not
include a number, it indicates
that the code is a continuation
from the previous line. Some
code lines can get rather long and
must be wrapped to be displayed
on the printed page. If you need
to type the code in Visual Basic,
be sure to put continued lines on
a single line.
23. 8 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
of the Person class would. The Display method for Employee could thus add level and salary
information to the displayed message when it is called.
This was just a brief introduction to OOP and some of its concepts. Visual Basic 2008
supports all of these concepts and many more. Throughout this book youāll see more OOP
concepts, and when you do, Iāll highlight them in a āreader aidā information box, as shown in
the left margin.
Hereās the complete listing used in this section with the addition of the Customer class:
34 Imports System
35
36 Public Class Person
37 āData members
38 Public Name As String
39 Public Address As String
40 Public City As String
41 Public State As String
42 Public ZIP As String
43 Public Country As String
44
45 ā Methods
46 Overridable Sub Display()
47 Console.WriteLine(Name)
48 Console.WriteLine(Address)
49 Console.WriteLine(City)
50 Console.WriteLine(State)
51 Console.WriteLine(ZIP)
52 Console.WriteLine(Country)
53 End Sub
54 End Class
55
56 Public Class Customer
57 Inherits Person
58
59 Public ID As Integer
60 Public IsPartner As Boolean
61
62 Overrides Sub Display()
63 Dim partnerMessage As String
64
65 If IsPartner Then
66 partnerMessage = ā is a partnerā
N O T E
In .NET, all classes ultimately
derive from the Object class, even
when it is not specified.
24. Chapter 1: Introducing Microsoft Visual Basic 2008 Express Edition 9
67 Else
68 partnerMessage = ā is not a partnerā
69 End If
70
71 Console.WriteLine(āCustomer ID: ā + ID.ToString())
72 Console.WriteLine(Name + partnerMessage)
73 Console.WriteLine(Address)
74 Console.WriteLine(City + ā,ā + State + ā ā + ZIP)
75 Console.WriteLine(Country)
76 End Sub
77 End Class
78
79 Public Class Employee
80 Inherits Person
81
82 Public Level As Integer
83 Public Salary As Integer
84
85 Overrides Sub Display()
86 Console.WriteLine(Name + ā is at level ā + Level.ToString() + ā and
has a salary of : ā + Salary.ToString() + ā$ā)
87 Console.WriteLine(āHis address is:ā)
88 Console.WriteLine(Address)
89 Console.WriteLine(City + ā,ā + State + ā ā + ZIP)
90 Console.WriteLine(Country)
91 End Sub
92 End Class
This is a simple case, but it illustrates some of the basic concepts of OOP.
What Is Visual Basic 2008 Express Edition?
Visual Basic 2008 Express Edition is the tool we will use throughout this book to develop
applications that run on Windows. The Express editions of Visual Studio 2008 were designed
25. 10 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
to focus on productivity. As with the high-end versions of Visual Studio 2008, the Express
editions are also what we call rapid application development (RAD) tools because their phi-
losophy is geared toward productivity. The Express editions of Visual Studio are easy to use,
easy to learn, and streamlined because although they contain mostly the same components,
they lack the full breadth of features found in the higher-end versions of Visual Studio. Most
features and components in the Express editions were simplified to make the learning curve
less steep and to fit the needs of the nonprofessional developer.
The Visual Studio 2008 Express editions were designed with beginner programmers in
mindāpeople like you who are curious about programming and who are looking for an
easy way to build Windows applications while learning how to program. Visual Basic 2008
Express Edition is the ideal tool to use to rapidly develop applications for topics you really
love or for hobbies you enjoy. You can also use it to help ease your day-to-day job or school
tasks. Most important, you can have fun with the tool while youāre learning to program.
What Kinds of Applications Can You Build with
Visual Basic 2008 Express Edition?
With this version of Visual Studio 2008, youāll be able to create the following types of
applications:
Windows applications
ā These are applications that have a graphical interface with
buttons, windows, menus, toolbars, and so on, as in Microsoft Word or Windows Internet
Explorer. With this book youāll be able to take full advantage of WPF, which lets you build
applications that create a rich user experience while exploiting all the power of your com-
puter. You can also build applications that look like Windows Vistaābased applications.
Console applications
ā These are applications that have no graphical interface and that
simply use text to communicate with the user. (Typically, these applications run in a com-
mand window or DOS window.)
Reusable components or class libraries
ā These are groups of tools created to help
build other applications.
What you wonāt be able to build are Web sites and Web services. To create any type of
Web application, you will need to get Microsoft Visual Web Developer 2008 Express Edition.
N O T E
We will look into the details
of what types of applications
fall into these categories in
Chapter 3, āCreating Your First
Applications.ā
26. Chapter 1: Introducing Microsoft Visual Basic 2008 Express Edition 11
What Are the Key Features You Need to Know About?
The following list, although not complete, provides the essential features of Visual Basic
2008 Express Edition. At this point, donāt worry if you donāt understand every feature listed.
Iām presenting the features in the list because youāll come across all of them in some way in
the fun sample applications you will be creating as you read this book.
Most of the features listed here emphasize the RAD philosophy. Although the idea is to
give you an overview of the interesting features that can make your life easier, the names
of the features alone are not sufficient to understand what they mean. Iāve included a brief
description giving you the essentials and explaining how they will help you develop applica-
tions.
Built-in Starter Kits
ā The Starter Kits are fully developed applications with best practices
and examples to follow. These applications will give you another example on which to
base your learning. They will be a good complement to what we are doing in this book.
You can find them at http://msdn2.microsoft.com/en-us/vbasic/ms789080.aspx.
Beginnerās targeted documentation and tutorials
ā These are a fast and easy way to
get information. They also provide samples.
IntelliSense
ā This feature provides real-time syntax suggestions and even finishes your
typing for you. In Visual Studio 2008, IntelliSense, as you will see, is everywhere (itās now
called IntelliSense Everywhere), and it provides a more complete and contextual set of
suggestions.
Code snippets
ā Snippets provide code for more than 200 programming tasks to help
you complete many common tasks automatically. In addition, code snippets show the
recommended way of performing a task. They are directly integrated into the develop-
ment environment, and they are extensible; that is, anybody can extend the existing snip-
pets or provide new ones. Over time Microsoft will continue to supply new code snippets,
and members of online communities will contribute their snippets as well. Code snippet
extensibility seems to be a really nice feature that will help people share useful features in
online communities.
My
ā construct This new Visual Basic feature provides simple access to popular .NET
Framework classes and common tasks. With it you can perform tasks without knowing
27. 12 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
all the framework internals. These tasks are nicely wrapped and provide you with an easy
and clean way of getting things done. Although similar to code snippets, the My con-
struct elements have their source code hidden and wrapped in one line of code.
Data-enabled applications
ā With these applications you can connect to Microsoft SQL
Server 2005 Express Edition and add databases and code to access the data in your appli-
cations. In addition, a new editor has been added to help you develop applications that
use data. As mentioned earlier, LINQ is one of the big new features of .NET 3.5 included
with Visual Studio 2008, and youāll see how to use it in Chapter 8, āManaging the Data.ā
Windows Forms Designer and WPF Designer
ā With these new tools, you can easily
design your Windows application using either Windows Forms or WPF, including features
such as snap lines, which make sure your controls are aligned in your form, and autocor-
rect, which gives you real-time compiler feedback. You wonāt have to compile your code
to know whether you have errors; Visual Basic 2008 will show them to you as you type
and even give you potential fixes.
XAML Editor
ā The XAML Editor lets you edit Extensible Application Markup Language
(XAML), which was introduced with .NET 3.0. This new markup language is used exten-
sively in WPF and Windows Workflow (WF) to describe user interface elements in WPF
and process logic in WF. (WF is beyond the scope of this book.)
XML Web services
ā Visual Basic 2008 provides easy-to-use tools and wizards that will
help you connect to published XML-based Web services and will help you utilize their
functionality.
New Windows Forms controls
ā These comprise an impressive list of controlsāa
greater selection than in any previous version of Visual Basic. They will help you create
user interfaces that have a professional look and feel.
Smart Tags
ā Most Windows Forms controls that come with the product include Smart
Tags. As in many applications of the 2007 Microsoft Office system, a Smart Tag is rep-
resented by a little black triangle, or an icon and a little black triangle, attached to a
control. A Smart Tag gives you access to the most common actions you can perform
on a control.
M O R E I N F O
XAML is also used in Silverlight
for Web applications, but this is
beyond the scope of this book.
28. Chapter 1: Introducing Microsoft Visual Basic 2008 Express Edition 13
ClickOnce deployment
ā With this feature you can easily publish your applications on
the Internet, on a local area network (LAN), on a network share, or on a CD. It also simpli-
fies publishing updates. In this new edition of Visual Studio, you can now use a wizard to
handle the Windows Vista User Account Control (UAC) so that your application runs in
the lowest user security context it needs. Usually you want to aim your software develop-
ment on Windows Vista at regular users. This has the effect of reassuring users that your
application wonāt perform unsafe operations without their knowledge.
Edit and Continue
ā While you are debugging your application, the Edit and Continue
feature lets you modify the code, move back and forth in the debugger, re-execute code,
add functionality, or fix bugs on the fly without stopping program execution.
Debugger visualizers
ā While you are debugging your application, the visualizers give
you an easy way to get readable representations of your application data. They give you
a human-readable representation of the stored data, even for more complex types found
in ADO.NET or XML.
Community Access and Start pages
ā With these features, you can access additional
information from online communities and from different sources of online help, including
diverse RSS feeds. (RSS can stand for Rich Site Summary or Really Simple Syndication and
is a family of XML file formats; it is widely used by the weblog community and news
Web sites.)
Simplified development environment
ā Everything in the development environment
was created so that you can easily access key functionality, tools, and objects.
As you can see, Visual Basic 2008 Express Edition includes many nice features to help
new programmers develop applications in a fast and fun way. These features will provide
guidance even when youāre not necessarily sure what syntax or components to use and will
greatly expedite learning the product.
29. 14 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
In Summaryā¦
You now know that .NET is a framework composed of compilers, tools, languages,
debuggers, and an execution engine. The CLR is that execution engine, and it is responsible
for loading and executing managed applications. In essence, .NET is like a house with the
CLR as the foundation and all other services built on top of it. You also learned that the CLR
didnāt change with Windows Vista and Visual Studio 2008, but a lot of new building blocks
have been added so you can take advantage of features provided by Windows Vista and
make developing applications easier.
In addition, you learned that Visual Basic 2008 is an object-oriented programming
language that has a simpler syntax than most modern programming languages. You also
started to learn what object-oriented programming is and the basics of OOP in Visual Basic
2008.
This chapter gave you the opportunity to hear about the most important features of
Visual Basic 2008 Express Edition. In the next chapter, youāll learn how to install Visual
Basic 2008 Express Edition.
30. 2 15
Preparing to Install
Visual Basic 2008 Express
Edition, 16
Installing Visual Basic
2008 Express Edition, 17
Chapter 2
Installing Visual Basic
2008 Express Edition
In this chapter, youāll install Microsoft Visual Basic 2008 Express Edition
and start getting to know what components are included with it. Iāll guide
you through all the steps of this installation so that you will be ready to start
building applications using Visual Basic 2008 Express Edition right away.
In addition, I will talk about some common installation scenarios, give you
some tips for installing the product, and cover what to do if the unexpected
happens.
The installation process is easy and straightforward, following in the spirit
of the Microsoft Visual Studio Express editions.
31. 16 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
You have a couple of options for installing Visual Basic 2008, particularly if youāve had
previous versions installed or if you installed an early (prerelease) version of the product.
Before you start the installation, make sure your computer meets the software and hard-
ware recommendations. Review the introduction of this book for all the necessary informa-
tion. You will also want to be sure that your computer has the latest updates from Windows
Updates (http://windowsupdate.microsoft.com) and Microsoft Updates (http://update.
microsoft.com). Installing the latest updates will ensure that your computer has all the lat-
est security updates along with some installation prerequisites before starting the product
installation.
If you have an antivirus or antispyware application installed and running, it might prompt
you to choose to allow certain setup tasks to proceed. For instance, with the latest Microsoft
Windows Defender (http://www.microsoft.com/athome/security/spyware/software/default.
mspx), I was asked two times to allow certain tasks to proceed, and a few other times the
antispyware product recognized the source and simply mentioned it and continued. If you are
using a different antispyware application, your experience might vary slightly, but it will bear
some similarities to this process. These antivirus and antispyware products are giving you an
opportunity to confirm the origin of the product youāre about to install. When youāre sure itās
from Microsoft, let the setup application continue its job by choosing to allow the action.
During the installation, if something goes wrong, youāre probably not the only person
to encounter the problem. Your first step is to look at the latest Readme information main-
tained by the setup team on MSDN and follow the steps provided to solve the installation
problem. Here is the link: http://www.microsoft.com/express/support/.
Side-by-Side Installation
If you have a previous version of Visual Studio on your computer, say Visual Studio 2002
or Visual Studio 2003, installing Visual Basic 2008 Express Edition (or any Visual Studio 2008
product) will be straightforward. This is considered a side-by-side execution, and you can go
straight to the āInstalling Visual Basic 2008 Express Editionā section about installing the
software.
Preparing to Install Visual Basic 2008 Express Edition
C A U T I O N
Please make sure you carefully
read the article at http://msdn2.
microsoft.com/en-us/vs2008/
bb964521.aspx before starting
the uninstall process!
32. Chapter 2: Installing Visual Basic 2008 Express Edition 17
Prerelease Versions of Visual Basic 2008 Express Edition
When you uninstall a prerelease version of any software, you might encounter problems.
At some point, you might have no choice but to reformat your hard disk and reinstall your
operating system. This situation is not uncommon when you work with prerelease software,
but there is a solution. Before beginning the uninstall procedure, and as a precautionary
measure, be sure to back up all your data. If possible, a good practice is to avoid installing
any prerelease versions of any products on your main computer. Using a test machine (or
virtual software) will help you avoid losing any important data and wonāt slow your produc-
tivity in the event something goes wrong. You can learn more about the virtual solution that
Microsoft offers, called Microsoft Virtual PC 2007, at http://www.microsoft.com/windows/
virtualpc/default.mspx.
Luckily with Visual Studio 2008, all Community Technology Preview (CTP) and preāBeta 2
versions were ātime-bombedā virtual images provided by Microsoft; therefore, the chance of
ruining your main computer has been almost eliminated. You simply have to delete the
Virtual PC image provided by Microsoft, and you should be good to go with the released
version of the product. But if you have installed Visual Basic 2008 Express Edition Beta 2 and
you didnāt use a Virtual PC image, you will have to uninstall the beta version before you
proceed with installing the released version.
Installing Visual Basic 2008 Express Edition
Now that weāve addressed a lot of potential issues and your computer is ready, you can
proceed with the installation. You will find a companion DVD with this book that contains a
full working edition of the product. Simply insert it into any available CD/DVD drive in your
system, and follow the steps listed next.
M O R E I N F O
Because of a new feature called
multitargeting, you can compile
any project to .NET 2.0, .NET
3.0, or .NET 3.5. After success-
fully installing Visual Basic 2008
Express Edition, you can safely
uninstall Visual Basic 2005 Express
Edition because with Visual Basic
2008 Express Edition, you can tar-
get .NET 2.0 and also get the ben-
efits and new features of Visual
Basic 2008 Express Edition.
N O T E
Even though Microsoft doesnāt
officially support prerelease ver-
sions of the software, you will
find resources on Microsoftās
Web site to help you with instal-
lation. In particular, you will find
information on how to uninstall
(and in what order to uninstall)
the products. Look at the forums
at the following address for help
on uninstalling any Beta 2 instal-
lations (youāll need to sign in
using a Windows Live ID to get
to this article): http://forums.
microsoft.com/msdn/showforum.
aspx?forumid=1346&siteid=1.
33. 18 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
TO INSTALL VISUAL BASIC 2008 EXPRESS EDITION
If autorun is enabled, the installation process should start automatically. If it doesnāt start
automatically after a few seconds, follow these steps:
1. Click the Start button, and then click Computer.
2. Right-click the CD/DVD drive that has the product media, and select Explore.
3. In the list of files, locate and double-click Setup.hta to start the Installation Wizard.
4. On the Welcome to Visual Studio 2008 Express Editions Setup page, click Microsoft Visual
Basic 2008 Express Edition.
Within a few seconds, you should see that
the setup program is copying all the neces-
sary installation files to a temporary folder, as
shown in Figure 2-1.
When the setup program is done copying
the files, the setup application loads into
memory. While the application is loading,
youāll see an initialization progress bar, as shown
in Figure 2-2.
Next, youāll be greeted by the Welcome to Setup page
(Figure 2-3), which provides some information about the
product and the possibilities youāll have working with it.
You can select the check box if you want to send anony-
mous data about your experience installing the product to
Microsoft. This program is totally anonymous, and you can
read the policy to see exactly what type of information will
be sent. Click Next to continue or Cancel to exit the installation program.
To continue the installation process, you must read and accept the license terms
(Figure 2-4). Please read the terms carefully to see what you can and canāt do with this
product. When you have finished and youāre ready to accept the license agreement, select
the option button that says you have read and accepted the license, and then click Next to
continue.
I M P O R TA N T
If you install Visual Basic 2008
Express Edition on the Windows
Vista operating system, you
should be prompted by the
Windows Vista User Access
Control dialog box to give the
setup process permission to
continue. If you have been using
Windows Vista for a while, you
have probably seen this dialog
box many times. Click Continue
to proceed with the installation.
Figure 2-1
Copying setup files locally to a temporary folder
N O T E
Youāll have nothing to do but wait
at this point. The wait should not
be longāless than a minute in
most cases, depending on your
computerās speed.
Figure 2-2
Initializing the setup process
M O R E I N F O
Youāll see a check box at the
bottom of the License Terms
page that enables Visual Studio
to receive and display plenty of
useful information, such as tips,
blogs, and samples about .NET
and Visual Basic. If you clear it,
you can always select it again
after the product is installed by
using the Tools menu.
34. Chapter 2: Installing Visual Basic 2008 Express Edition 19
Figure 2-3
Welcome to Setup page
Figure 2-4
License terms
The Installation Options page appears, as shown in Figure 2-5. On this page, be sure to
specify that you want access to the Help system (MSDN Express Library) and Microsoft SQL
Server 2005 Express Edition.
SQL Server 2005 Express Edition is a relational database management system (RDBMS)
with which you can easily manipulate data in your application. This is an important step. For
example, if youāre creating the DVD collection management application that is included as
one of the Starter Kits, all the data related to your DVD collection will need to be stored in a
database using SQL Server 2005 Express Edition.
N O T E
The only reason not to install the
local MSDN Help or SQL Server
2005 Express Edition is limited
hard disk space. Be sure you
understand the consequences
of your selections. If you donāt
install MSDN Express Library,
youāll need access to the Internet
to get help from MSDN Online. If
you donāt install SQL Server 2005
Express Edition, you wonāt be able
to create applications that need
to access other sources of data,
such as Microsoft Access database
information, XML files, or other
types of RDBMS information. In
addition, some sample files from
this book wonāt work automati-
cally, and youāll have to perform
some manipulations or re-instal-
lations to get them to work.
35. 20 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
Figure 2-5
Setting your installation options
The last product to install is Silverlight. Although we wonāt use Silverlight directly in this
book, I strongly recommend you install it because you will have a smoother and richer
experience on many Web sites. Silverlight 1.0 will not take up a lot of disk space, because it is
only a few megabytes.
When youāre done with your selections, click Next to continue.
The Destination Folder page appears, as shown in Figure 2-6. This page will ask you
where to install the software on your computer. I recommend you use the default location.
Click Install to start the installation. The installation progress bar appears, which means
the installation is underway! (See Figure 2-7.) This might be a good time to get something to
drink because the installation could take some time.
M O R E I N F O
Silverlight, previously named
WPF Everywhere (WPF/E), is a
cross-browser, cross-platform
plug-in for delivering the next
generation of .NET-based media
experiences and rich interactive
applications for the Web. From
a user point of view, Silverlight
behaves like Adobe Flash, but
Silverlight is richer in terms
of what you can do and, more
specifically, how you can do it.
With Silverlight 2.0, for example,
you will be able to use your
Visual Basic skills and expertise
to develop Silverlight applica-
tions. You can find nice samples,
documentation, and much more
about Silverlight at http://www.
silverlight.net.
C A U T I O N
If you choose to install the soft-
ware in a folder other than the
recommended default, you might
have problems working with
some of the paths and files men-
tioned later in the book. If you
do install in a different location,
rest assured Iāll give you some
cautionary notes whenever you
might run into problems.
N O T E
The installation time will vary on
the basis of your choices on the
previous page. On average, if you
selected both MSDN Library and
SQL Server 2005 Express Edition,
the installation should take about
10 to 30 minutes, depending on
your computerās speed.
36. Chapter 2: Installing Visual Basic 2008 Express Edition 21
Figure 2-6
Destination Folder page
Figure 2-7
Installation Progress page
Here is the list of components that will be installed:
The .NET Framework 3.5
ā This was the outer circle of the image illustrated in
Figure 1-1.
Visual Basic 2008 Express Edition
ā This is the tool itself.
Microsoft SQL Server Compact 3.5
ā This is a version of SQL Server that lets you, as
the developer, embed a compact database on smaller devices, such as Windows Mobileā
based phones or even on your Windowsābased desktop or laptop.
MSDN Express Library for Visual Studio 2008
ā This was described earlier.
SQL Server 2005 Express Edition
ā This was described earlier.
When the Setup Complete page appears (see Figure 2-8), you are now finished with the
installation. That wasnāt too painful, was it? Before you click the Exit button, please read the
following notes.
37. 22 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
Whenever you install a new application, itās always a good habit to go to Microsoft
Update (http://update.microsoft.com) or Windows Update (http://windowsupdate.microsoft.
com) to get all the high-priority updates. Or you can click the Microsoft Update hyperlink
from the setup application, as shown in Figure 2-8. I prefer Microsoft Update because you get
all the updates you need for all the Microsoft software already installed on your hard disk.
Youāll get updates for Windows, the Microsoft Office system, SQL Server, Windows Defender,
and the .NET Framework along with your hardware drivers updates, all in one stop!
Itās also important to verify that your antivirus application
and its signatures are up-to-date and that you have updated
antispyware installed. Finally, in Control Panel, open the Security
Center, and make sure all lights for the firewall, virus protection,
automatic updates, and all other security settings are green. If
not, address those issues to prevent any security hazards.
Click the Exit button when you are done. If you elected to
send the feedback of your installation to Microsoft on exit, the
setup application will send it to Microsoftās servers, as shown in
Figure 2-9.
Figure 2-9
Sending installation feedback to the
Microsoft servers
T I P
In the future, more products will
be added to the list of products
supported by Microsoft Update.
Figure 2-8
Setup Complete page
38. Chapter 2: Installing Visual Basic 2008 Express Edition 23
In Summaryā¦
This chapter focused on installing Visual Basic 2008 Express Edition. It addressed most
issues you might encounter during the installation, it covered different setup scenarios, and it
provided links to MSDN for more help.
After working through this chapter, you should now have the .NET Framework 3.5, Visual
Basic 2008 Express Edition, MSDN Express Library for Visual Studio 2008, SQL Server Com-
pact 3.5, Silverlight 1.0, and SQL Server 2005 Express Edition installed and ready to go. Your
computer should also be up-to-date with all updates installed and all security settings on
green.
Whenever youāre ready to explore the integrated development environment (IDE) and
write your first two applications, just jump to the next chapter.
40. 3 25
Three Types of
Applications: What Are
the Differences?, 26
Getting Started with the
IDE, 28
Building the Projects, 31
Chapter 3
Creating Your First
Applications
Youāve installed Microsoft Visual Basic 2008 Express Edition, so now itās
time to create your first applications. Youāll start this chapter by learning
about the differences between console applications, Windows applications,
and Windows Presentation Foundation (WPF) applications. Youāll then look
at the integrated development environment (IDE). As its name implies, the
IDE is the application that provides all the tools you need to design, plan,
develop, and distribute your applications. You could use any text editor, such
as Notepad, for example, to create your applications, but in this chapter and
for the reminder of the book, youāll be using the IDE.
Most programming books usually start with a fairly simple application
called āHello, World.ā Your first application will be a simple application as
well, but youāll be creating an application that does a little bit more than just
say āHelloā to the world. Specifically, youāll learn to create an application that
adds two numbers together and outputs a result. With this application youāll
also learn about Solution Explorer as well as the documentation and Help
system built into Visual Basic 2008 Express Edition.
41. 26 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
In this chapter, youāll create two versions of the same application: a console application
and a Microsoft Windows application. You might wonder why you even have to worry about
the type of application when youāre creating a program. Often, the type of application you
create depends on the purpose of the application and how users will interact with it.
Sometimes your application doesnāt need to have a graphical interface. For instance,
some applications need to be executed in a script or a batch file, or they donāt need a
graphical interface because no user usually interacts with the application except to start it.
This type of application is called a console application because everything is displayed in a
system console window. You might have heard these types of windows referred to by many
different names: a DOS window, a command prompt window, or simply the command
window. The most common output in a console application is simple text.
Figure 3-1 shows the result of the famous āHello, Worldā application as a console
application.
Figure 3-1
A console application
Three Types of Applications: What Are the Differences?
N O T E
Please note that console appli-
cations are still executed in
Windows but in the console.
M O R E I N F O
Simple text (also called ASCII characters) is the usual output of a console
application, but some console applications use ASCII graphic characters.
(ASCII stands for American Standard Code for Information Interchange.)
An ASCII code is the numerical representation of a character (such as 0
or #) or an action of some sort. Pressing Enter in a word processor to
move to a new line of text is an action represented by an ASCII character,
for instance. The ASCII graphic character set, also called extended ASCII
characters, includes vertical lines, vertical double lines, corners, and much
more. ASCII characters are sometimes used to create boxes around text in
console applications. Unicode characters are similar to ASCII but are not
encoded in the same way. They are more extensive and can represent dif-
ferent locales.
N O T E
Console applications can be
written in many different pro-
gramming languages (C, C++,
C#, Visual Basic, and so on) and
scripting languages (Perl, Python,
JScript, and so on).
42. Chapter 3: Creating Your First Applications 27
Console applications can be much more complex
than the āHello, Worldā example shown here. In fact,
they can have as rich a set of features as Windows
applications. The only difference is that they donāt have
a graphical interface. For example, in corporate data
centers, many applications execute all day and night,
producing a large amount of data. It would be time-
consuming and problematic to rely on people to verify
the data. So, data centers are usually highly automated
to facilitate this job; they use console applications that
produce, manipulate, and verify the data in scripts or
batch files.
In contrast to a console application, a Windows
application has a graphical interface, as shown in
Figure 3-2. (This type of application is also called a Windows
Forms application in .NET.)
These applications are usually accessible from the Windows
Start menu, and by default they share some common characteristics,
such as a Close button, a Maximize button, and a Minimize button, as
shown here:
A third type of applicationāa WPF applicationāalso
has a graphical interface and looks similar to a Windows
application; however, WPF applications use a completely
different set of libraries to generate their executable
files. For our work in this chapter, it is enough to say that
WPF applications can provide a richer experience and
use a different approach for their design.
Figure 3-3 shows a WPF application in action. I will
explain them much more fully in Chapter 6, āModifying
Your Web Browser.ā
Figure 3-2
A Windows application includes a graphical
interface.
Figure 3-3
A WPF application
N O T E
A Windows service is a type of
Windows application that runs
on Windows in the background;
it doesnāt have a user interface,
doesnāt produce any visual out-
put, starts when Windows starts,
and doesnāt even require a user to
be logged in to start executing.
Windows XP Service Pack 2 (SP2)
and the Windows Vista operat-
ing system come with roughly
four dozen Windows services. For
example, one built-in Windows
service validates your user name
and password at start-up.
43. 28 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
To get started writing the code for the console version of your first application, youāll need
to start Microsoft Visual Basic 2008 Express Edition. To do this, follow these three easy steps:
click Start, click All Programs, and then click Microsoft Visual Basic 2008 Express Edition.
Before we go further, letās pause and admire the IDE in all its glory. Look at Figure 3-4,
and feel the excitement.
Figure 3-4
The IDE in all its glory
Getting Started with the IDE
N O T E
The first time you start Microsoft
Visual Basic 2008 Express Edition,
it will take some time to load
because the IDE is being config-
ured for the first time.
44. Chapter 3: Creating Your First Applications 29
If youāre not feeling the excitement yet, you soon will be. The development environment
has been designed to make a lot more information available up front and to make you more
productive more quickly. From this screen, everything you need to build an application is
available in a couple of clicks. This is where you type your code, compile your code, launch
the application, find your mistakes and fix them, get help on the syntax, and perform many
other tasks. Furthermore, the Visual Basic 2008 Express Edition IDE is designed to generate a
lot of code for you so that you have less to type. If you didnāt have the IDE and you wanted
to write a Windows Forms application, you would have to type a lot more code, and this is
prone to errors. With the IDE, most of the actions youāll perform will automatically generate
the code for you behind the scenes.
As you spend more time with the IDE, youāll find that there are many ways to perform
the same actions. For instance, to complete a specific action, you can use a series of menu
choices, you can use a keystroke shortcut, you can click an icon on a toolbar, you can click a
hyperlink in a page, or you can right-click and choose an option from a context-sensitive
menu. Before diving into our first application and before writing some code, weāll go
through each big component of the IDE.
The first page you see when you start the IDE is a really useful one: the Start Page. It
contains a lot of useful information:
Recent Projects pane
ā Here youāll get the list of projects or solutions that were
recently opened. You can also create a new project or open an existing project that is
not in the list.
Getting Started pane
ā I call this useful pane āHelp Centralā because if you need
quick help, this is one of the best places to get answers. Whether you need help with
some Visual Basic constructs, you want to see a list of how-to articles, or you simply
want hyperlinks to communities of programmers, you can often find these items in the
Getting Started pane of the IDE.
Visual Basic Express Headlines pane
ā This is where you find specific news about Visual
Basic Express Edition from Microsoft. These product headlines deliver special messages
specific to Visual Basic 2008 Express Edition and announce new updates, new releases,
new code snippets, or anything that needs attention on your part.
T I P
The first and only rule of this
book is to not be afraid to experi-
ment. Click, look, read, and try
whenever possible. This is really
the best way to learn. Iāll show
you some important material,
tips, and tricks throughout this
book, but my advice to you is to
go beyond these examples and
just try and try and try.
N O T E
I will show you how and where
to look for this generated code
in Chapter 5, āUsing Rapid
Application Development Tools
with Visual Basic 2008.ā
N O T E
Some hyperlinks on the Start
Page require a live connection to
the Internet. So if you are unable
to read the hyperlinks, please
verify your Internet connection
status.
45. 30 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
MSDN feeds
ā This pane of the Start Page includes hyperlinks to articles from one of
MSDNās Really Simple Syndication (RSS) feeds. You can configure these articles for any
valid RSS feed from the Web. The default is set to the MSDN Visual Basic 2008 Express
RSS feed. These articles are usually different from the ones under Visual Basic Express
Headlines; occasionally they might be the same, but the articles from MSDN cover not
only Visual Basic Express Edition but also topics including Visual Studio Team Systems,
Microsoft SQL Server, Web services, and so forth. You can modify the feed by clicking
Tools and then Options, expanding Environment, selecting Startup, and updating the
Start Page News Channel field with a valid RSS feed of your choice..
Some important components of the IDE are not part of the Start Page:
Menu bar
ā This is where you can select and perform almost all possible actions related
to your projects, files, and Help. The options available change based on the current
context. For example, when you donāt have a project open, you have fewer menu choices:
File, Edit, View, Tools, Window, Community, and Help. When a project is open, the menu
choices will also include Project, Build, Debug, and Data.
Main toolbar
ā This toolbar contains icons that are essentially shortcuts to popular
actions that you can also perform by going through the menus.
Toolbox
ā The Toolbox contains controls that are used in your applications. If you scroll
over the Toolbox on the left side of the Start Page, the Toolbox will expand. If you donāt
have a project open, the Toolbox will be empty. At this point you can think of controls as
visual elements in Windows applications that possess a graphical interface. For instance,
once a project is opened, the Toolbox will include buttons, labels, text boxes, menus,
toolbars, and so on. Iāll explain these controls in greater detail in Chapter 5.
Solution Explorer
ā This feature lists the files and components in your project. If no
project is open, it will be empty. Youāll learn more about Solution Explorer later in this
chapter.
Status bar
ā The status bar displays a wide variety of information corresponding to
the state of certain active operations. For instance, when you load a project, youāll see a
N O T E
The Microsoft Developer Network
(MSDN) is a set of online and
offline services designed to help
developers write applications
using Microsoft products and
technologies.
N O T E
If you donāt see Startup and other
settings in the Options dialog
box, ensure that you select the
Show All Settings check box
in the lower-left corner of the
Options dialog box.
T I P
If you accidentally close the Start
Page and you want to display
it, you can always get it back by
clicking View, Start Page.
46. Chapter 3: Creating Your First Applications 31
message on your screen such as āLoading project c:blablablabla.vbproj from your hard
drive.ā When youāre building an application, youāll see something like āBuild started,ā and
when the application has finished, youāll see āBuild succeededā or āBuild failedā depend-
ing on the success of the process.
Building the Projects
From this point on, youāll focus on what you really came here to do: build some projects.
Letās start with your first applicationāthe console version of the application that adds two
numbers together.
Building a Console Application
Weāve been talking about what a console application can do and what it will look like, so
why donāt we build one? In this section, youāll create a simple mathematic application.
TO BUILD A CONSOLE APPLICATION
1. If Visual Basic 2008 Express Edition is not running, start it by clicking Start, All Programs,
Microsoft Visual Basic 2008 Express Edition.
You can choose to start building your application either by clicking the New Project icon
on the toolbar, by selecting Create: Project from the Start Page, or by clicking File, New
Project on the menu bar.
2. In the New Project dialog box, select Console Application in the Templates section, and
type MyFirstConsoleApplication in the Name box. The New Project dialog box should
be similar to the one in Figure 3-5. Click OK to create the project.
T I P
For demos and samples, I recom-
mend you type all the source
code in the following examples
so that you can better understand
the concepts involved. However,
for longer source code listings,
you can also download the com-
pleted code samples (http://
www.microsoft.com/mspress/
companion/9780735625419).
N O T E
By default in Visual Basic 2008
Express Edition when you click
OK, projects are created in a
temporary location. When you
save or close the project, files are
saved in DocumentsVisual Studio
2008Projects. (On Windows XP
and Windows Server 2003, youāll
find them in My Documents
Visual Studio 2008Projects.)
You can change the default proj-
ect location by clicking Tools,
Options, Projects and Solutions
and finding the first text box
named Visual Studio Projects
Location. Weāll look into what
files are created and what their
content is in Chapter 5.
47. 32 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
Figure 3-5
Creating a console application using the New Project dialog box
You should now see the IDE in an idle state waiting for you to write the applicationās
code. Your screen should look like the one shown in Figure 3-6.
Getting to Know Solution Explorer
Before you write the code, you need to learn about Solution Explorer. Shown on the right
side of the screen in Figure 3-6, Solution Explorer provides an organized view of your
projects and all the files associated with them, as well as some useful commands in the form
of a toolbar. Youāll find all the source code files, the project settings, the resource files (such
as the application icon), the configuration files, and so on, in Solution Explorer.
T I P
If you accidentally close Solution
Explorer, you can get it back by
clicking View, Solution Explorer.
48. Chapter 3: Creating Your First Applications 33
Figure 3-6
MyFirstConsoleApplication without the code
If you want more information about Solution Explorer, you can always do a search in the
Help system and product documentation. Before trying to perform a search, please read the
next section; youāll learn a lot about all the information that is at your disposal.
T I P
Note that the Start Page is still
available; itās simply a separate
tab. You can go to any window by
clicking a specific tab or by press-
ing Ctrl+Tab.
49. 34 Microsoft Visual Basic 2008 Express Edition: Build a Program Now!
Getting Help: Microsoft Visual Studio 2008
Express Edition Documentation
If you want to read more about Solution Explorer, you need to be introduced to Help
and the documentation system. You access the documentation by pressing F1 from within
Visual Basic 2008 Express Edition or by using the Help menu. The first time you press F1 or
use the Help menu, youāll be greeted with the Online Help Settings dialog box, as shown in
Figure 3-7.
Figure 3-7
Online Help Settings dialog box
This dialog box prompts you to choose a primary Help source; you can choose online
Help as a primary source, local Help as a primary source, or no online Help at all. Think
about your options carefully. If you donāt have a broadband (cable, DSL, or satellite) Internet
connection, I suggest you choose local Help as the primary source; otherwise, choose online
Help as your primary source since it is the best source for the latest information.
50. Chapter 3: Creating Your First Applications 35
Once youāve made your selection, youāll see the documentationās graphical interface, as
shown in Figure 3-8.
Figure 3-8
Microsoft Visual Studio 2008 Express Edition documentation
The toolbar at the top of the window includes several interesting elements that will
help you find exactly what you need. Figure 3-9 shows the most important buttons on the
toolbar.
52. āThe public debt, enormously increased for the last fifteen years,
the civil list, the crown revenue, the pensions of the royal family, are
not within the limits of our control. Every debt is sacred, but some
are yet in suspense. For example, whilst all the European powers
were largely indemnified according to their pretensions (English
claims even to three times the amount allowed to French creditors),
had the United States shown some hostile feelings towards us, or
had they merely asserted their claims in concert with the other
powers, their demands would have been immediately liquidated. But
they have never yet been adjusted, because that nation would not
join the enemies of France, who were then to be found in her
bosom, notwithstanding what has sometimes been said at this
tribune to the contrary.
āWith regard to the civil list, gentlemen, it might perhaps be
desirable, both for its proper management and the personal comfort
of the king, that the appropriations not included within the kingās
personal expenses should have been granted under the forms of
accountability adopted in the civil list of England.
āThe appropriation for the criminal judiciary department furnishes
me another opportunity of again proffering my warmest wishes for
the abolition of capital punishment, which the uncertainty of human
comprehension renders so alarming, and which must particularly
appall those generations who have so irretrievably suffered from the
furies of parties; and also for the abolishment of branding, called for
on all sides. May the minister at the head of the judiciary
department affix his name to these two salutary measures!
āOne of my honorable friends has adverted to the gratuitous
magistracy of English justices of the peace. I do not envy this
pretended benefit of our neighbors, and it is my opinion that those
great proprietors are not the most proper persons to exercise a
sovereign jurisdiction over all the petty offences committed within
their department; but I cheerfully concur in the unanimous voice for
restoring the principle of temporary election in justices of the peace.
āNothing can be more gratifying to my feelings than to have
heard, on the last discussion on trials by jury, the pledge that the
propriety of extending the benefit of this institution to the
53. transgressions of the press will be taken into consideration at the
next session.
āI cannot withhold my assent to the observations of the report on
the whole of ministerial budgets. I had myself said at this tribune in
1819, āIt would be highly beneficial that every ministry should
inquire, with all conscientious severity, into what is necessary to the
due performance of their duties, and should propose in all remaining
details, terms as generous and complete as they please, for the
security and comforts of those actually in office, provided that
ministers should be divested of all parasitical service, and children
brought up to a more profitable labor than the industry of obtaining
situations, which is so detrimental to every kind of industry, and to
the independence of a vast number of citizens.ā The specification,āI
mean the application,āwhich can never be too minute, of every
appropriation to every item of expenditure, has already made some
progress; but how profuse those specifications, beyond which there
is ministerial exertion, when compared with English budgets, of
which I now hold in my hand three departments,āthe artillery, war,
and navy; and yet this is not a cheap government, to use an
expression that has so often been charged upon me, and which I am
so unwilling to deny.
āThe minister for foreign affairs has opened his career under the
most critical circumstances; his official duties will be dictated by the
loyalty of his personal character. The great political question is now,
to decide whether this government will continue to follow the track
of old diplomatic traditions, or whether, divested of all foreign
influence and reminiscence, it will boldly assume the rank it
behooves us to take at the head of European civilization; a post
which, in my opinion, has always remained vacant, notwithstanding
appearances contradicted by facts; a stand to which no foreign
power any longer dares lay any claim. From that exalted station,
France may and ought to resist coalitions in which none of her
interests are involved. For my own part, I should have expected
more satisfactory explanations and details before giving my assent
to the late loan of eighty millions, but none would more readily
consent to the measures necessary for the liberty and independence
55. institution originally founded on social equality, as hostile to the
rights and opinions of the people thus calling, as it were, for a sort
of retaliating animadversion against opinions and practices that are
totally distinct from worldly ambition. I will seek for the solution of
that inextricable dilemma of the duty of the priest, considered both
as speaking in the name of Heaven, and as a pay officer of state;
but where shall I find it but in that country where religious freedom
is more generally prevalent than in France, where the ministers of
religion are more respected, and sectarians live in peace; in that
government where no rights and regulations can give umbrage, but
where, being altogether foreign to and distinct from all civil
institutions and form of government, religious societies are formed
without restraint and choose their own ministers.
āThe separation of the ecclesiastical department from the ministry
of public instruction, I consider as much an act of piety as of sound
judgment. But too much has yet been left to the infringements of
the Catholic clergy. It is not only a religion of the state, but also a
very prevailing one still to be found in those ordinances which ought
to have secluded its special dogmas within the walls of the church,
and confined its distinction of creeds to the circle of private families.
āNational instruction, gentlemen, and especially elementary
education, that main-spring of public reason, of practical morality, of
public peace and comfort, is at present the first want of the French
population, as it is the first duty of government. You all know,
gentlemen, how this duty is to be discharged. Methods of instruction
have heretofore been protected in an inverse ratio to their being
perfect and easy. Neither your paltry vote of 50,000 francs, nor
500,000 francs, can be adequate to the redemption of that most
important of all social obligations. Under a competent and legal
system of public instruction, I would consider five millions as the
most desirable appropriation of a budget.
āMany statesmen appear to have forgotten,āsome perhaps have
never been aware,āthat by the law of the 3d Brumaire, year IV.,
France was provided with the best system of instruction that ever
existed in any country. It could not be consistent with that power
which severed from the institute the class of moral and political
56. sciences. Napoleon created the university, the monopoly and
exigencies of which wounded the feelings of private families and
displeased the true friends of liberty, but which was afterwards
indebted to the invasion of Jesuitism, a privilege of another kind, for
the credit of being looked upon as a liberal institution. In order to
satisfy all parties it would be necessary, at the next session, to offer
a plan for the organization of public instruction, wherein all the
national duties of teaching should be strictly laid down, and all
individual liberties respected; but every plan of education,
particularly in its elementary bearings, would require the co-
operation of true civil administrations.
āWhy is it, gentlemen, that in utter contempt of the most solemn
pledges, we have preserved for fourteen years the whole imperial
structure of the internal administration in France? those factitious
municipalities, those unsettled councils, those despotic and turbulent
prefectures and sub-prefectures, which have never been amended
except for successively adding to their inconveniences, attributions,
and appointments? When shall we see every section manage its own
concerns, provide for all its own exigencies, and retain within its
territory that portion of the taxes that we are afterwards compelled
to send back to it? Is this idea unknown in France? But the
constituent assembly, whatever has been said to the contrary at this
tribune, had not only proclaimed useful and true doctrines; it had
also organized a system of administration elected by the citizens,
and was abolished only by the consulate and by the empire. Is it
replete with such great difficulties? But when in 1815, Napoleon, in a
fit of liberalism, restored the municipalities in accordance with the
law of ā91, elections were made with remarkable celerity and
moderation. The only embarrassment that could arise would be in
the government, if instead of abiding by the dictates of eternal truth
and of contemporary reason, it found it necessary to combine
principle with exception, right with privilege, thereby perplexing and
deluding the purest intentions.
āI will follow the report of the committee in the examination of the
war department, merely with the view to support the proposition of
placing in the civil list the payment of the kingās military household.
57. You have also heard on this subject the excellent discourse, to which
my honorable friend, General Gerard, has given all the weight of his
experience and of his glory. The minister of war, in offering
observations that will be made the subject of future deliberations,
has just expressed his desire of completing our system of defence.
Here, gentlemen, we naturally bring back to our memory the urgent
call recently made by the ministry upon our patriotism to obtain the
means necessary to a preserving policy, a respectable military
strength, a guarantee of public tranquillity, a national dignity; and to
an union of the people with the government. The minister had
before represented the nation rising in a body at the voice of their
king. I will not attempt, gentlemen, the solution of the problem; the
knot has been untied by a celebrated writer whose authority is daily
referred to.
āThe stationary National Guard, says an ordinance of the king,
dated March, 1815, comprising a mass of three millions of landed
and industrious proprietors, constitutes a local force extended on
every point....
āFrom this formidable mass, whose dearest interests attach them
to the soil, may be formed voluntary corps constituting movable
columns....
āThus the nation, fighting on every point with the army, either in
the line or as auxiliaries, will prove that a great people cannot
unwillingly be brought under the yoke that they have once shaken
off.
āGentlemen, I will only remind the government that eight years
ago, in the session of 1820, the ministers then acknowledged that
they had been in possession, for eight months, of the project of a
law drawn up by a special commission, and you all know how it has
hitherto resulted.
āThe glory of the French navy has resounded in every heart. The
name of Navarino has been proclaimed with an unanimous concert
by the throne and in the chamber, as it had been echoed by the
whole nation; the brave Admiral de Rigny is perfectly secure against
the censure of a recall. The infamous traffic of human flesh has been
partly suppressed, but it is not yet totally extinct. With an entire
58. confidence in the sentiments of the minister of marine on these
important questions, I submit to his wisdom the idea of placing the
slave trade on the same footing as piracy, as the law of the United
States has given the example, since followed by England. With
regard to the management of our colonies, gentlemen, there is so
much to say that I could not briefly enter on the subject. I will
merely remark that the system of colonization of the ancients is, in
any opinion, much preferable to that of modern times.
āIn the law under consideration the minister of finance has
undoubtedly surpassed all his colleagues; but when a thorough
discussion is about taking place, I do not feel sufficient confidence to
anticipate the opinions that you will hear from colleagues more
learned and more skilful than myself. I should even consider myself
worthy of reproach, had I not made it a duty to offer some of my
ideas, but especially to call at this tribune for more effectual social
reforms than can possibly be achieved by way of amendments.ā
La Fayette was constantly the recipient of attention and
distinguished honors, both in America and in France. The young men
of Auvergne gave him a splendid banquet on the 23d of June, 1828.
The old generalās toast was: āTo the assembled young men of the
three departments of Auvergne, and to our dear mountains; the
volcanoes of these are extinct, but the sacred fire of liberty will
never be extinguished among them.ā
The marquis never forgot any of his friends, especially his
American comrades, and his affection for the fathers was continued
to the sons, as the subjoined letter to Charles A. Clinton, written to
him by La Fayette upon receiving the news of the death of his father,
De Witt Clinton, will demonstrate.
āParis, March 30, 1828.
āMy dear Sir: Your personal and friendly attentions to me make
you a natural organ of the melancholy and affectionate feeling which
I wish to be conveyed to the family of your lamented father. I regret
the mournful and unexpected event as an immense loss to the
public, and a great personal cause of grief to me. Bound as I was to
59. the memory of my two beloved Revolutionary companions, your
grandfather and grand-uncle, I had found a peculiar gratification in
the eminent talents and services of their son and nephew, and in his
kind and liberal correspondence, until personal and grateful
acquaintance had impressed me with all the feelings of a more
intimate friendship. I beg you to be to your afflicted family the
interpreter of my deep sympathies, and to believe me forever
āYour most sincere friend,
āLa Fayette.ā
At the celebration of the commencement of the Ohio and
Baltimore Railroad, which occurred on the 4th of July, 1828, a pair
of handsome morocco slippers, and a pair of beautiful white satin
shoes were made by the cordwainers during the procession. The
morocco slippers were presented to the venerable Carroll, on the
ground; and the white satin shoes were subsequently transmitted
to General La Fayette, together with the badges worn by the
association. This compliment received the following reply:ā
āLagrange, Sept. 11, 1828.
āGentlemen: With affectionate feelings of pleasure, I have
received your kind letter, the badge bearing a likeness of our
matchless Washington, and of my excellent friend, the surviving
signer of independence, the ensigns of your association as they
were worn by your worthy president, and an elegant pair of ladiesā
white satin slippers, which were manufactured in the procession.
For those gratifying marks of your remembrance and friendship, I
beg you to accept my most grateful thanks. The anniversary of
American independence, the commencement of the Baltimore and
Ohio Railroad, have been happy associations. So I have seen, as it
were, the commencement of your city in the first years of the
Revolutionary struggle, of which this very day is one of the (1777)
anniversaries, that of the battle of Brandywine; and it has been
lately to me a matter of proud delight to witness the immense
progress of Baltimore, a great and rapid increase of which we may
now more than ever anticipate. Its happy effects upon every sort
60. of trade and industry cannot be doubted, and I offer you the
cordial congratulation and good wishes of your sincere and obliged
friend,
āLa Fayette.ā
The general also transmitted the following to the book-binders
of the city, and to the editors of the American:ā
āLagrange, Sept. 11, 1828.
āTo the book-binders of Baltimore.
āGentlemen: With a lively sense of gratitude, I have received your
kind letter, and a copy of the apron and badge which on the late
celebration, doubly dear to an American heart, were worn by the
book-binders of Baltimore. Testimonies of your remembrance and
affection are at all times highly gratifying to me, nor could they
prove more welcome than on this momentous occasion, when the
anniversary day of independence is hailed in common with the
commencement of one of its most promising results, amidst the
immense progress of every kind that has taken place since it has
first been my happy lot to be admitted as a soldier of the United
States, and particularly as a citizen of Maryland. I am proud to
have been enabled to show specimens of American book-binding
which every day excite European admiration. I beg you,
gentlemen, to accept the respectful acknowledgments and
affectionate good wishes of a veteran who would have been
happy, in the procession, to have followed his venerable friend, the
surviving signer of the glorious declaration; and to have expressed
to you, on that great day, the sentiments of his deep gratitude and
warm attachment.
La Fayette.ā
āAfter other business during the second session of the twentieth
Congress the Vice-President communicated a letter from the
President of the United States, transmitting one received from
Monsieur David, the artist, member of the Institute of France,
61. professor of the School of Painting at Paris, and member of the
Legion of Honor, who presents to Congress the bust of General La
Fayette, which has been received with it.ā
The following is a translated copy of the letter:ā
āParis, Sept. 11, 1828.
āTo the President: I have made a bust of La Fayette, and would
willingly raise a statue to his honorānot for himself, because he
has no need of it, but for ourselves, who approve in so lively a
manner the desire of expressing to him the affectionate regard
and admiration with which we are inspired. The youth of the
French nation is filled with admiration for the virtues of the youth
and the old age of him whose likeness I send you.
āThey envy the glory that was acquired upon the American soil,
by the side of the immortal Washington, and the defence of your
noble rights.
āThey envy that glory which has been acquired on the soil of
France, in the midst of the troubles of Paris and of Versailles,
where, in breasting the storm, he wanted courage as little in the
struggles of debate as he did in contending with the sword. They
envy the glory which covers the brow whitened by age, but still
sparkling with the fire of liberty and of patriotism.
āIt is in the name of this youthful feeling of the French nation,
ambitious to imitate everything generous and great, that I offer
you a work upon which my hands have been employed for some
time and with great care.
āI could wish that it was more worthy of the subjectāmore
worthy of the place which I am desirous to see it occupy. Yes, sir, I
could wish that the bust of our brave general, of our illustrious
deputy, should be elevated on a pedestal in the audience chamber
of Congress, near the monument erected to Washington himself;
that the son be placed by the side of the father, or, if you please,
that the two brothers in arms, the two companions in victory, the
friends of order and of law, may be no more separated in our
estimation than they were in their devotion to the cause of liberty
and in the hour of peril.
62. āLa Fayette is one of the ties that unite the two worlds. He
visited the new one to remain there for a few months, and to
salute once more your sacred land of justice and equality, and has
returned to us after having partaken of your feasts and received
the honor and the benediction of your nation.
āI hasten to render my homage in returnāI present you with his
image. It will be a memento that the original may often recall to
the National Assembly those eternal principles upon which the
independence of the state reposes, and which are the foundation
of their safety.
āI am, with profound respect, Mr. President, your very humble
and obedient servant,
āDavid,
āMember of the Institute of France, and
professor in the School of Painting; member
of the Legion of Honor.ā
64. oppression, and institutions founded on the rights of man, and the
republican opinion of self-government?ā
āOn the right side is the following:ā
āāLa Fayetteās last words in his answer to the Presidentās farewell
speech, Washington, Sept. 7, 1825: God bless you, sir, and all who
surround us. God bless the American people, and each of their
states, and the federal government. Accept this patriotic farewell
of an overflowing heart; and such will be its last throb when it
ceases to beat.āā
The New York American of December, 1828, says:ā
āA letter from General La Fayette, of December 29, from
Lagrange, tells usāand as he belongs to the nation, we may
repeatāthat Madame Perier (the eldest daughter of Mr. George La
Fayette) has just made him a great-grandfather. The same letter
says, āI expect to be in town in a few days, and enjoy the
agreeable American society which has convened there from the
several parts of the Union. It will be something like a Washington
winter.āā
The following is the substance of General La Fayetteās address at
the Fourth of July dinner in Paris, in 1829:ā
āThe health of their venerable guest, General La Fayette, having
been given, the general in returning thanks, stated the pleasure
which he felt in celebrating this anniversary, which enabled him, as
it were, again to breathe the American atmosphere. He spoke with
high gratification of their associating him with the principles for
which he had struggled under the illustrious and well-beloved
Washington. The independence of the United States began a new
era of political civilization, which will finally extend over the whole
world, and which is founded on the natural rights of mankind. He
was proud to own that the first declaration of those rights bore the
indelible imprint of its American origin. He referred in eloquent
terms to the delight with which all generous minds had hailed the
recent triumph in Great Britain over religious intolerance, and
earnestly advised the Americans in consolidating their constitution
not to listen to European suggestions, nor admit any exotic
materials. He concluded by giving a toast to āNational Legitimacy,ā
65. which, while it choked and destroyed the weeds of privilege,
nourished the roots of natural and solid right.ā
In 1829 General La Fayette came into possession of a large
property under the indemnity law, being the fortune of his own
and his wifeās family, of which the Revolution had deprived them.
We will quote from one more speech of La Fayette, in the French
Chamber of Deputies, on the 9th of July, 1829. The question under
discussion was the accordance of an eventual credit of fifty-two
millions of francs.
āGentlemen,ā said La Fayette, āthough I have voted against
approving the budget of expenses, in the hope that its refusal
would prove a prompt and efficacious means of obtaining those
institutions and economies which France has for so long a time
expected, yet I feel disposed to vote in favor of the credits
demanded, provided the chamber receives those explanations
which it stands so much in need of. I do not see in the great
quarrel of the east, as regards ourselves, anything beyond our
importance as an intermediate power in what is called the balance
of Europe; only two classes, the oppressors and the oppressed; in
the demarkation of states, nothing but their natural limits; in the
well-being of a people, nothing but the advantage of all; and in
the policy of France, nothing but a liberal and independent part to
act. You know, gentlemen, that great and powerful alliance which
would enslave and brutalize the human family. It covers the
peninsula with blood, oppresses Italy, and throws other states into
disorder. Vienna is its metropolis, and in spite of other pretensions,
Don Miguel is its ideal type.
āEngland has pretended to favor the world with another beacon,
whose light is sometimes extinguished, and at other times shines
but to decoy; upon this point inquire of Italy, of Spain, and of
Portugal. It is for France then, gentlemen, which finds herself
more in accord with our ideas of the new civilization, to place
herself at the head of that civilization; in that consists her glory
and her interest; there, too, in case of need, will be found her
ambition; and there, also, the dignity and the safety of her
government. But to perform that noble task it is necessary that the
66. government resolve no longer to fear either a representative or an
armed nation, and that abandoning its former relations, it may be
able to say to foreign powers, āNext to God, it is to the people of
France that I am indebted for being elevated above your influence
and beyond your pretensions.ā
āI will confine myself, gentlemen, to a few remarks on the
grounds to which our attention has been invited by the application
made for the credits now under consideration.
āSome of my honorable friends have spoken harshly of the
expedition to the Morea; they have even thought that it was in no
degree whatever entitled to public approbation; but I have so
ardently desired some kind of interference, particularly French
interposition, in behalf of Greece, that I cannot join them in their
criticisms, and as to our portion of that generosity which was
manifested in the relief afforded, without speaking of Russia,
whose motives are obvious, it would be sufficient to advert to two
discourses from the throne, in one of which the battle of Navarino
is called by Charles X. glorious, while from George IV. it received
the appellation of untoward, to prevent us from confounding the
shades of the two interests in the cause of Greece, and to mark
the distinction between the cannonading at Terceira and the
hospitality at Brest. The last protocol, however, from London has
humbled my pride and diminished my expectations.
āWhy, gentlemen, have the Greeks taken up arms? why have
they endured so many calamities? why have they so freely shed
their blood? It was to free themselves from paying tribute to the
Turks; to build up again their ancient country; and to enjoy in their
own way the blessings of self-government. But now, gentlemen,
the protocol brings into fresh existence the odious tribute; the
greatest part of Greece is shut out from Greece, and to govern the
small portion which remains it is proposed to look, I know not
where, or for whom, but for some foreign prince, a hospodar, a
mongrel of the East and of the West, in whom the Greeks will only
behold a vassal of the Porte, and for whom they must pay an
additional tribute.
69. āI will conclude, gentlemen, by observing that the explanations
which the discussions may produce shall decide my vote.ā
At a sitting of the Chamber of Deputies General La Fayette made
the following remarks on the āHoly Allianceā:ā
āThere was a vast and powerful league which desired to
command and brutalize the human species. It has oppressed Italy,
devastated the peninsula, and had disturbed other states. Its chief
seat is Vienna, and Don Miguel its ideal type. England has
pretended to set up another system, but it was only to lure states
to their ruin. It was the business of France to place herself at the
head of civilizationāher glory, her interest, and her ambition to
require it; but to fulfil this noble destiny it was necessary that the
government should determine not to fear either a nation
represented or a nation armed, and, renouncing all connections, it
should say to foreign powers, āAfter God, it is to the French people
that I am indebted for being placed above your influence and
beyond your pretensions.āā
During 1829 General La Fayette made a tour through some of
the French provinces, and his reception by the people appears to
have rivalled the enthusiasm displayed in his honor in the United
States. One London paper says:ā
āNever was a king so feasted and treated as this venerable
remnant of the Revolution has been. In every quarter he has been
received with shouts of triumph and congratulatory addresses,
which, while they have been complimentary to him, have
generally, also, been made the vehicle for strong philippics against
the new order of things. From Grenoble to Lyons the road was
thronged by continual crowds of people who came to testify their
regard for the principles which had guided his political conduct,
and the esteem which they entertained towards himself
personally.ā g The Times observes: āThe old general, from his early
services in the cause of liberty,āfrom his immense sacrifices for
his country,āfrom his intrepid consistency of character during a
political career of forty years, during which the world turned
around him or changed its principles several times, while he
remained unchanged, is deservedly an object of great esteem and
70. admiration. But why is he brought forward, or why does he make
himself prominent on this occasion, type as he is of the
Revolution? And why, when he does appear, is he so
enthusiastically received? For no other reason but because the
king has made choice of what is considered a counter-
revolutionary cabinet, and because the people are desirous of
evincing their adherence to the free institutions which they think at
present threatened, by testifying their grateful admiration for one
of the founders and champions of their freedom. Every shout of
applause thus uttered for General La Fayette is a shout of defiance
against the ministers; and every libation poured to his health is a
kind offering to the memory of past struggles for liberty. The
repetition of such scenes would have been thought impossible
about two months ago.ā
The following description of General La Fayetteās reception at
Lyons is taken from an extract of a letter dated Paris, Sept. 16,
1829:ā
āGeneral La Fayette has paid a visit this summer to his birthplace
in Auvergne, and has been received on his passage in a manner
worthy of his noble virtues, public as well as private. From his
arrival at Chavaniac until his entry at Lyons, in every town and
village through which he passed, he has witnessed the
spontaneous homage of the patriotism of their inhabitants. The
population of villages far distant from the road he travelled
precipitated themselves before him on his passage, and the
inhabitants of the cities through which he passed presented
themselves en masse to welcome him within their walls. In spite of
the orders sent by the ministry at Paris to the departmental
authorities, to endeavor to suppress as much as was in their power
the preparations made to receive the general, his triumphal march
since he left La Grange, from the borders of the river Manche, to
the foot of the Alps, has no other example in history, excepting his
visit to the United States. Escorted from city to city by large
cavalcades of horsemen, through arches of triumph prepared for
the occasion on the high roads, saluted continually with
enthusiasm by assembled multitudes, the thoughts of the veteran
73. āAt the dessert the following toasts were given:ā
ā1. By the presidentāThe King of France.
ā2. āGeneral La Fayetteāother warriors have been victorious in
battle, and other orators have pronounced eloquent discourses;
but none have equalled him in civic virtues.ā
āGeneral La Fayette then rose and said:ā
āāYou have been witnesses, gentlemen, of the marks of affection
and confidence with which the population of Lyons has deigned to
receive me within their walls; you yourselves have participated in
that kind reception in a manner so flattering, and I am surrounded
at this patriotic banquet by objects of such interesting
associations, that it would be superfluous, and above all
impossible, to express to you my feelings at this moment; the
remainder of my life, gentlemen, will be consecrated to them. I am
proud and happy that my visit here has furnished another occasion
to your city to express its constant hatred of oppression, its love
for true liberty, and its determination to resist every attempt of the
incorrigible contre-revolution.ā The general then spoke of the
privileges granted to the people by the constitution; their rights of
being tried by jury, and of elections, and of the censorship of the
press; and after having paid a just tribute to the noble and
patriotic attitude that the National Guard of Lyons took at the
important epoch of 1815, he took occasion to examine the position
of the Polignac ministry, and the violent measures which it
threatens against the liberties of France. āWe are menaced,ā said
he, āby hostile projects; but how will they be effected? Will they
succeed by means of the Chamber of Deputies? My honorable
friend and colleague, M. Couderc, now at my side, and every one
of my colleagues who are now seated at this banquet, will attest
that in the moment of danger the Chamber of Deputies will show
itself faithful to patriotism and honor. Is it proposed to dissolve the
Chamber? If so, it will then be the business of the electors of
France, who certainly will return only deputies worthy of
themselves and of the nation.
āāIs it contemplated to vitiate the elections by more ordinances,
and thus exercise illegal power? Let the partisans of such
75. still were, and there Mr. Romain Peyron thus spoke, in the name of
his fellow-citizens:ā
āāMr. Mayor and Mr. Deputy: The inhabitants of this commune
have learned with the greatest pain that, by a decree of the
minister of the interior, you were deprived of the functions you
have discharged with so much zeal, and in which you have so
justly acquired the confidence and esteem of those whom you had
to serve. The motives which have afforded the new ministry a
pretext for this act are too honorable to be made a cause for
complaint! You are, gentlemen, the first citizens stripped of their
official functions for having taken part in the honors paid to
General La Fayette! Let us not envy the enemies of the public
liberties this poor satisfaction while all France is still echoing with
the acclamations which everywhere burst forth upon the passage
of this great citizen, and especially in the second city of the
kingdom!
āāThe general who was the object of this enthusiasm will live in
history, in spite of the calumnies of party men! The people will
always recollect that he was, at that time, the zealous defender of
legal liberty, which, among us, includes attachment to
constitutional monarchy; that, on the 5th and 6th of October, he
twice saved the lives of the royal family; that, previously to the
10th of August, he sacrificed his popularity in order to snatch Louis
XVI. from the dangers that threatened him; and that, proscribed
for his energetic protest at the bar of the Legislative Assembly, and
arrested in a neutral country, he expiated, in the dungeons of
Austria, the crime of having always faithfully observed the line of
duty!
āāYou, gentlemen, you too, fulfilled a duty, in not separating
yourselves from all these under your care, in those imposing
circumstances when the presence of our magistrates, as the
organs of our unanimous sentiments, added a new value to their
manifestation, and ensured tranquillity and good order in the midst
of our rejoicings.
āāReceive, therefore, the expression of our thanks and of our
regret.āā
76. These testimonies of the esteem of their fellow-citizens
abundantly compensated for the vengeance of the ministers.
The prefect of the department, having designated M. Buscaillon
as provisional mayor, that respectable old man answered, āthat M.
Finant having been removed by the minister of the interior for
having taken part in the honors paid to General La Fayette, he was
bound to declare that he himself had done the same thing,
together with all the other inhabitants of the commune, and that
he could not, therefore, trouble the minister to do justice upon
another in similar error.ā
M. Buscaillon will long be remembered for his noble refusal of a
place dishonored by so gross intolerance.
77. CHAPTER XIV.
The Revolution of 1830āProclamation to the French PeopleāFrom
the Journal du Commerce, ParisāProclamation of Louis Philippe
āLa Fayetteās Official Announcement to the Municipality of Paris
āOrder of the Day issued by General La FayetteāDetails of the
RevolutionāCharles X. driven from the ThroneāThe Deputies,
escorted by the National Guards, offer the Throne to the Duke of
OrleansāThe Dukeās ReplyāHe is made Citizen KingāChanges
in the CharterāLa Fayetteās Speech in the ChamberāLetters by
La Fayette concerning this Political UpheavalāHis Opinions
regarding French AffairsāReview in the Champ de MarsāOrder
of the Day to the National GuardsāLa Fayetteās Account of the
RevolutionāLa Fayetteās Personal Influence in Franceā
Compliments of the London Press regarding himāLa Fayette
speaks on Capital Punishment in the ChamberāLetter from Paris
regarding La Fayetteās PopularityāEncomiums in his Honorā
Letter from Count de LasteyrieāIncident of the Revolutionā
Resignation of La FayetteāComments of the National Gazetteā
La Fayetteās Speech on the Slave TradeāHis Remarks concerning
the National GuardāLa Fayette sums up the Results obtained by
the Revolution of 1830āThe Victory PopularāThe Dynasty of
Right Divine expelledāNational Sovereignty declaredāNational
Guard establishedāLiberty of the Press securedāTrial by Jury
appliedāNew Electoral LawāElective AdministrationsāLa
Fayette receives a Deputation from PhiladelphiaāAddress of the
American MinisterāLa Fayetteās Courteous and Patriotic Reply.
78. Welcome to our website ā the ideal destination for book lovers and
knowledge seekers. With a mission to inspire endlessly, we offer a
vast collection of books, ranging from classic literary works to
specialized publications, self-development books, and children's
literature. Each book is a new journey of discovery, expanding
knowledge and enriching the soul of the reade
Our website is not just a platform for buying books, but a bridge
connecting readers to the timeless values of culture and wisdom. With
an elegant, user-friendly interface and an intelligent search system,
we are committed to providing a quick and convenient shopping
experience. Additionally, our special promotions and home delivery
services ensure that you save time and fully enjoy the joy of reading.
Let us accompany you on the journey of exploring knowledge and
personal growth!
ebookultra.com