eb Matrix is a freeware tool that has been created with the help of some ASP community leaders. Despite its shortcomings, Active Server Pages (ASP) is one of the most popular Web development platforms available today. This is mainly because the basic concept, altering HTML output through script, is very easy to understand. In ASP.NET, most of the shortcomings of ASP have been remedied but some of the simple concepts of ASP have been sacrificed in the process. Not that the basics of ASP.NET are much harder to understand, but ASP.NET requires a completely different way of thinking (compared to ASP).
Microsoft realized that getting people to switch from ASP to ASP.NET wasn’t something that would happen overnight, and one of the major factors in the development of Web Matrix was to make ASP developers quickly feel at home with ASP.NET. In order to do so, Microsoft involved many ASP community leaders in the Web Matrix project, letting them beta test the editor and provide feedback on the editor’s feature set. The result is that not only is Web Matrix an easy editor to work with if you come from an ASP background, but it also has the support from the community that it needs to make ASP.NET popular. In addition, the editor contains links to the major community sites, newsgroups, forums, and listservs. In addition, Microsoft has integrated MSN Messenger support into the editor so you can ask questions to your buddies without leaving the editor. This truly makes Web Matrix a community editor.
Installing Web Matrix
Web Matrix is a freeware tool from the Microsoft ASP.NET team. You can download it from http://www.asp.net/webmatrix/, where you will also find a guided tour. Because the whole application is written in .NET (C# to be exact), the application is extremely small considering its capabilities. The download is only 1.2 MB. If you don’t already have a SQL Server or Microsoft Desktop Engine (MSDE) running on your machine (or a server), I suggest you also download and install MSDE. That download is significantly larger (33 MB), but the database functionality that you get with Web Matrix is aimed at SQL Server or MSDE, so working with other databases is really not an option unless you want to start digging around in the code. Some features of the editor will not work with any other database.
Installing Web Matrix is about as easy as it can get. Just open the downloaded file and the installation program will guide you. You really don’t have anything to choose, so you only need to accept the license agreement (read it first).
Development Environment
The Web Matrix development environment is reminiscent of Visual InterDev, as you can see in Figure 1. It consists of the usual menu and toolbar (1), and an editing window (2). The editing window is surrounded by a toolbox (3) on the left, and on the right a workspace window (4) and a property grid (5). The editing window opens in Design mode by default (but you can change this behavior through the Options dialog). Design mode provides you with a WYSIWYG design surface that shows you how your page will look after you render it in a browser. The Web Matrix design surface is similar to the design surface in Visual Studio .NET, though it can be a little buggy at times. If it doesn’t render your page properly and it doesn’t give you an error message, you can alter the underlying HTML and you have a good chance that it will work again at some point. You can alter the underlying HTML through either HTML mode or All mode. The former only shows the HTML of the page, without the code in the block and any declarations, whereas the latter shows all the code in the page. Switching between the different modes works fine, but you need to be aware that Design mode will alter your HTML after you switch to it. The downside to this is that it might insert white space, but on the positive side it does nicely indent your code, making it easier to read and track down problems. The Code mode shows you only the code inside the block, without the tags. One nice feature is that the code and the HTML are in the same page, but using the Code and HTML modes, you can work as if you are working with code in a separate file (i.e., code behind). All the modes that show code or HTML use color coding for HTML, C#, and Visual Basic, but the absence of both IntelliSense and code completion does slow programming down a bit. Although Web Matrix is a technology preview, it is not likely that Microsoft will implement IntelliSense or code completion, because that would make Web Matrix a more serious competitor to Visual Studio .NET.
![]() |
Toolbox The right side of the screen contains the toolbox, which you can make (in)visible by pressing F2. It contains the main tools you'll need to create pages. The toolbox consists of five sections:
My Snippets HTML Elements, Web Controls, and Custom Controls
|