Av rating:
Total votes: 11
Total comments: 2


Ludmal De Silva
ASP.Net configuration
19 January 2006

Using Visual Studio 2005’s WSAT to configure your web application

Configuration is one of ASP.NET’s powerful features. Although it can be used in production sites by simply editing the web.config XML file, we tend to forget how to add impersonation or custom error pages to the configuration file, or we are unaware of XML’s case sensitivity. For these reasons, editing web.config is not particularly user friendly.

A tool within Visual Studio 2005 simplifies that task. Web Site Administration Tool, or WSAT, enables you to manage your configuration using a simple web interface. Think of it as a visual editor for the web.config file. It’s also handy if you need to manage the site remotely.

When you make changes to the settings in the WSAT, they will be reflected in the web.config file and your application will restart. While you are developing your site, you can start the WSAT by clicking the ASP.NET configuration in the web site menu.

WSAT set up

As shown in the screen image above, WSAT is divided into three main sections: security, application and provider. Under the security tab, you can specify the authentication mode using the wizard, define users and groups, and indicate directory permissions and create access rules.

The application section, which is significant for developers, enables you to easily manage general application settings, such as creating name/value pairs, and access these values in the code using the ConfigurationManager class. You can also configure Simple Mail Transfer Protocol (SMTP) settings and trace and debug problems with your web application. This is where you take your application offline for maintenance as well, enabling you to edit pages or other files without worrying that a page will be called while you’re working.

Under the provider tab you can test or assign providers for membership and role management of your web site. WSAT configures and uses Microsoft SQL Server Express edition by default, and it creates a database in the App_Data folder. You can use a different provider for your membership management.

Important things to remember

Like editing the web.config file, the changes you make in the WSAT take effect immediately and require that the web site be restarted. Since this causes active sessions to be lost, always make configuration changes to a development version.

The WSAT will also time-out for security reasons. If it’s idle for a specified amount of time with being saved, your changes will be lost.

Finally, WSAT is only available with Visual Studio 2005. You can find WSAT source code in:
%Systemroot%\Microsoft.NET\Framework\v2.0.50215\ASP.NETWebAdminFiles.

Conclusion

WSAT is an excellent tool that enables developers to manage their web site configuration settings easily and efficiently. To read more about it, see http://msdn2.microsoft.com/en-us/library/yy40ytx0.aspx.



This article has been viewed 9967 times.
Rate this article:   Avg rating: from a total of 11 votes.


Poor

OK

Good

Great

Must read
 
Have Your Say
Do you have an opinion on this article? Then add your comment below:
You must be logged in to post to this forum

Click here to log in.


Subject: SQLEXPESS vs. SQL 2005
Posted by: Anonymous (not signed in)
Posted on: Friday, November 24, 2006 at 10:09 PM
Message: I have heard that WSAP is only cleanly integrated with Microsoft SQL Server Express, even if you have SQL Server 2005 installed on the server. Is this true? What's the simplest, easiest to understand, method for using SQL Server 2005 for the data repository of WSAP, instead of SQLEXPRESS.

Subject: run you can run the aspnet_regsql.exe,
Posted by: Anonymous (not signed in)
Posted on: Thursday, December 14, 2006 at 4:27 AM
Message: Hi,

you can run the aspnet_regsql.exe,
in the following directory..
c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_regsql.exe
This will register the schema with the Sql Server 2005 Database.

 






recommended site pinvoke

PInvoke.net is a user-driven wiki which provides .NET developers with native method signatures, so they don't have to spend time writing them from scratch.





Damon Armstrong
Customizing the Login Page in SharePoint 2007
 Damon shows how a few simple steps lead you to being able to include the login form in a consistent look and feel to...  Read more...


ANTS Profiler and the Un-Rest Cure
 After a while, successful applications can get set in their ways. Bart Read and Andrew Hunter decided... Read more...

Silverlight-Speed Loop
 John Bower steps up a gear, produces a Lamborghini, and examines the process of using a high-speed... Read more...

Sid: Vicious
 Dan Archer documents his epic struggle with an apparently simple task of authenticating user... Read more...

Embedding Help so it will be used
 It is not good enough to make assumptions about the way that users go about getting help when they use... Read more...

Optimising a High-Performance Computing Tool
 Many computer systems nowadays have their ‘correctness’ checked using sample testing, but this isn't... Read more...

A Complete URL Rewriting Solution for ASP.NET 2.0
 Ever wondered whether it's possible to create neater URLS, free of bulky Query String parameters?... Read more...

.NET Application Architecture: the Data Access Layer
 Find out how to design a robust data access layer for your .NET applications. Read more...

Web Parts in ASP.NET 2.0
 Most Web Parts implementations allow users to create a single portal page where they can personalize... Read more...

Visual Studio Setup - projects and custom actions
 This article describes the kinds of custom actions that can be used in your Visual Studio setup project. Read more...

Beginning ASP.NET 2.0
 It seems that there is both excitement and confusion surrounding Master Pages and Themes. A big part of... Read more...

Over 150,000 Microsoft professionals subscribe to the Simple-Talk technical journal. Join today, it's fast, simple, free and secure.

Join Simple Talk