<asp:Label id="messageLabel" runat="server" />
</form>
</body>
</html>
You can start the web server by executing the project: select Debug > Start Without
Debugging, or use the keyboard shortcut Ctrl-F5. Visual Web Developer will
load Hello.aspx in your system’s default web browser, as shown in Figure 5.15.
Figure 5.15. Executing a page using Visual Web Developer
We executed this project without debugging it, but generally you’ll want to run
projects with debugging enabled (using F5, or Debug > Start Debugging). The
debugging features enable you to find and fix errors in your code; we’ll learn more
about them towards the end of this chapter.
To enable debugging, you must modify an option in a file called Web.config,
which is your web application’s configuration file. We’ll take a more in-depth
look at Web.config shortly. For now, all you need to know is that the first time
you try to debug the project, Visual Web Developer will ask you whether you
want to enable debugging in Web.config using a dialog like the one in Figure 5.16.
Click OK to confirm the action.
Once you click OK, the application will execute. The resulting browser window
should be the same as the one we saw in Figure 5.15, but this time you have more
control over your application, as we’ll soon see.
You can tell that your application doesn’t run through your local IIS if you look
at the URL loaded in the browser window. When you execute a project using the
integrated web server, it will run on a random port, and the complete URL location
will reflect the physical path. In Figure 5.15, you can see that the integrated web
server was running on port 1855, which explains the complete URL: http://loc-
158
Chapter 5: Building Web Applications