Chapter 1. Introduction

With its release for the .NET platform, the Visual Basic language has undergone dramatic changes. For example:

  • The language itself is now fully object-oriented.

  • Applications and components written in Visual Basic .NET have full access to the .NET Framework, an extensive class library that provides system and application services.

  • All applications developed using Visual Basic .NET run within a managed runtime environment, the .NET common language runtime.

In this introduction, I briefly discuss these changes and other changes before showing you three very simple, but complete, Visual Basic .NET applications.

What Is the Microsoft .NET Framework?

The .NET Framework encompasses the following:

  • A new way to expose operating system and other APIs. For years, the set of Windows functionality that was available to developers and the way that functionality was invoked were dependent on the language environment being used. For example, the Windows operating system provides the ability to create windows (obviously). Yet, the way this feature was invoked from a C++ program was dramatically different from the way it was invoked from a Visual Basic program. With .NET, the way that operating system services are invoked is uniform across all languages (including code embedded in ASP.NET pages).

    This portion of .NET is commonly referred to as the .NET Framework class library.

  • A new infrastructure for managing application execution. To provide a number of sophisticated new operating-system services—including code-level security, cross-language class inheritance, cross-language type compatibility, and hardware and operating-system independence, among others—Microsoft developed a new runtime environment known as the Common Language Runtime (CLR). The CLR includes the Common Type System (CTS) for cross-language type compatibility and the Common Language Specification (CLS) for ensuring that third-party libraries can be used from all .NET-enabled languages.

    To support hardware and operating-system independence, Microsoft developed the Microsoft Intermediate Language (MSIL, or just IL). IL is a CPU-independent machine language-style instruction set into which .NET Framework programs are compiled. IL programs are compiled to the actual machine language on the target platform prior to execution (known as just-in-time , or JIT, compiling). IL is never interpreted.

  • A new web server paradigm. To support high-capacity web sites, Microsoft has replaced its Active Server Pages (ASP) technology with ASP.NET. While developers who are used to classic ASP will find ASP.NET familiar on the surface, the underlying engine is different, and far more features are supported. One difference, already mentioned in this chapter, is that ASP.NET web page code is now compiled rather than interpreted, greatly increasing execution speed.

  • A new focus on distributed-application architecture. Visual Studio .NET provides top-notch tools for creating and consuming web services -- vendor-independent software services that can be invoked over the Internet.

    The .NET Framework is designed top to bottom with the Internet in mind. For example, ADO.NET, the next step in the evolution of Microsoft’s vision of “universal data access,” assumes that applications will work with disconnected data by default. In addition, the ADO.NET classes provide sophisticated XML capabilities, further increasing their usefulness in a distributed environment.

An understanding of the .NET Framework is essential to developing professional Visual Basic .NET applications. The .NET Framework is explained in detail in Chapter 3.

Get Programming Visual Basic .NET now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.