Chapter 2. Hello World

The previous chapter introduced the ASP.NET architecture. In future chapters, you will learn all about creating web applications with ASP.NET. The current chapter presents a whirlwind tour by creating a simple web page to show you how easy it can be.

It is a long-standing tradition among programmers to begin the study of a new language by writing a program that prints “Hello World” to the screen. In deference to tradition, our first web page will do just that.

The tool you are most likely to use when developing ASP.NET applications is an integrated development environment (IDE), such as Visual Studio .NET. You may use any editor you like, however -- even the venerable text editor Notepad.

There are a number of advantages to using an IDE such as Visual Studio .NET. The Visual Studio .NET editor provides indentation and color coding of your source code, the IntelliSense feature helps you choose the right commands and attributes, and the integrated debugger helps you find and fix errors in your code.

The disadvantage of using an IDE, however, is that it may do so much work for you that you don’t get a good feel for what is going on in your application. It is like bringing your car in to the mechanic; he does all the work for you, but you never really learn how your engine works.

As a beginner, you may be better off doing more of the work yourself, giving up the support of the IDE in exchange for the opportunity to see how things really work. In this chapter, ...

Get Programming ASP .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.