beautypg.com

Configuring for release mode, Packaging your web application – Pitney Bowes MapXtreme User Manual

Page 465

background image

Appendix A: How to Create and Deploy a MapXtreme Application

Building a Web Application

MapXtreme v7.1

472

Developer Guide

Configuring for Release Mode

When you have completed the modifications, you are ready to do a release build.

An important concept to understand in ASP.NET 2.0 is that Visual Studio 2005/2008 knows nothing
about compiling a Web Application project. Previously, ASP.NET 1.1 and Visual Studio .NET would
build the code-behind source code and web forms and place the compiled code in an output
directory. Visual Studio 2005/2008 delegates all compilation responsibilities to the ASP.NET
platform. The Visual Studio 2005 /2008 build command only validates the Web Application
configuration.

To configure your Web Application project to be packaged without debugging turned on, you can
change a configuration setting in the Web Application project’s Web.config file. In the Web.config,
find the XML element "compilation" (line 27) and change the value of the attribute "debug" to "false".
The result should read as follows:

This Web.config setting lets the ASP.NET compiler know to build all source code in release mode.

To build the application, right-click on the ThematicsVB project in Solution Explorer and choose Build
Web Application.

Packaging Your Web Application

Creating a package for a Web application is similar to creating a package for a desktop application.

Create a Web Setup Project

To start we are going to add a Web setup project to our solution. To create a Web setup project:

1. In the Solution Explorer, right-click the Solution and choose Add > New Project. The Add New

Project dialog box displays on the screen.

2. In the Project types list, expand Other Project Types, and click on Setup and Deployment.

3. From Setup and Deployment Projects, select Web Setup Project. Click OK. A Web setup

application project will be created.
If your project is not part of a Solution, you will not see the Add Project shortcut. You can add the
Setup project from File > Add Project and choose Setup. A solution will be created along with the
Setup project.