Tim TrottTim Trott.ninja { color:black; visibility:hidden; }

What is Microsoft .Net?

By , Friday 9th November 2007 in Visual Studio

Microsoft .Net (dot-net), also known as the .Net Framework, provides the necessary compile-time and run-time platform to build and run .Net based applications.

The .Net platform also provides a set of technologies that enable a common environment for all applications written using a .Net language. The .Net Framework is designed with ease of use and code re-use in mind, and features many programming languages that can interact with each other.

In the .NET Framework, code is organized into hierarchical namespaces and classes and is divided into several key technologies: Common Language Specifications, consisting of the Base Class Library and Common Type Specification among other components, and the Common Language Runtime. In most cases the classes provided by the .Net framework can be extended through inheritance as the class hierarchy is not hidden from the developer. Only classes that have been marked as sealed cannot be extended.

Languages of .Net

Microsoft .Net has many languages that support the .Net framework. Microsoft's existing language, Visual Basic, has been upgraded to .Net and for the first time supports Classes and Object Orientation. Microsoft C++ has also been revamped to support the .Net framework.

Microsoft has introduced a new programming language called C# (C Sharp) which was designed specifically for the .Net platform. C# is derived from C++ and shares very similar syntax and constructs.

There are many other languages that support the .Net framework, such as Perl, Java, J# and Pascal (Delphi). This website deals specifically with the C# language.

The Following diagram shows how the .Net framework is structured and how each platform interacts with those around it.

Overview of the .Net Platform
Overview of the .Net Platform

Common Language Specification

The Common Language Specification (CLS) defines how the language interacts with objects and how objects interact with other objects. The CLS also provides a single set of data types for all languages, using a component called the Common Type Specification (CTS). If you have done any C++ programming you will be familiar with the C++ string being a character pointer (PChar or char*). In .Net a string is the same in all languages, so a Visual Basic application can call a method in a C# class library without the need for type conversion.

On the .Net platform, you don't have one rule describing how objects in C# behave and another rule describing how they should behave in Visual Basic. To steal a phrase, there is now "One rule to bind them all". Objects in Visual Basic and C# share the same methods and properties, same class behaviour and the same lifecycle.

In existing models, API's are used to interface with the Operating System or hardware. There was no consistency between different interfaces, parameter types had to be converted between languages and return types were often pointers to memory locations. With the introduction of the .Net framework everything is now part of a common system, and the nightmare of API programming is finally over.

Common Base Class Library

Taking the Common Type Specification one step further, the .Net platform provides a set of common classes. This also allows for code compatibility between languages. A button class in C# is the same as a button class in VB.Net or ASP.Net.

The Base Class Library also defines hundreds of classes, which you can use in your applications, so you spend less time working on class development and more time on productivity and functionality.

Common Language Runtime

Traditionally a software application written for the Windows environment would need to be completely re-written, sometimes in a different programming language, in order for it to be able to run on a handheld device or other hardware platform. The .Net environment removes this re-coding and allows code to be used on any hardware platform supported by the framework. This technology, or component, of the .Net framework is called the Common Language Runtime (CLR). The CLR provides a managed environment for code execution, which performs certain maintenance functions and memory management. These are covered in more depth in the Common Language Runtime tutorial.

Summary and Conclusions

The Microsoft .Net platform provides developers with an environment that is platform and operating system independent (as long as it supports the .Net Framework). Developers spend more time developing the functionality of the program and less time re-writing code for different platforms.

The Common Language Specification allows other .Net language components, programs, class libraries etc... to seamlessly interact with each other.

The .Net Common Language Runtime provides a managed environment where memory is managed (Garbage Collection), it manages security, deployment and execution.

In the next tutorial we will look at the languages that support the .Net framework in more detail.

My website and its content are free to use without the clutter of adverts, tracking cookies, marketing messages or anything else like that. If you enjoyed reading this article, or it helped you in some way, all I ask in return is you leave a comment below or share this page with your friends. Thank you.

About the Author

Tim Trott

Tim is a professional software engineer, designer, photographer and astronomer from the United Kingdom. You can follow him on Twitter to get the latest updates.

Further Reading
3 thoughts on “What is Microsoft .Net?”
  1. Gravatar
    hassan huamyun

    hey nice introduction , it is the first time i have been to this website . Thanks alot.

  2. Gravatar

    Thank you, this is the best .NET tutorial site!

  3. Gravatar
    Rob Coulton

    Brilliant. This is the most succint and understandable summary of the framework I have ever seen.

    The next time someone asks me "what is this dot net thingy" I will direct them to this web page.

    Thanks very much

Leave a Reply

Your email address will not be published.