网站导航免费论文 原创论文 论文搜索 原创论文 网学软件 学术大家 资料中心 会员中心 问题解答 原创论文 大学论文导航 设计下载 最新论文 下载排行 原创论文 论文源代码
返回网学首页
网学联系
最新论文 推荐专题 热门论文 素材专题
当前位置: 网学 > 编程文档 > ASP.net > 正文

MigratingfromASP.NET1.xtoASP.NET2.0

来源:http://myeducs.cn 联系QQ:点击这里给我发消息 作者: 用户投稿 来源: 网络 发布时间: 12/10/12
soft Management Console (MMC) snap-in for IIS that lets you decide which applications should use which versions of the .NET Framework.

Click here for larger image.

figure 6. MMC display of ASP.NET applications

the MMC IIS tab lets you to choose which version of ASP.NET your application uses and displays the Web.config location.

in addition to managing the framework version, the console has an "Edit configuration" button that lets you visually edit most of the Web.config settings without having to directly manipulate the Web.config XML file. As an administrator, you will find that this MMC snap-in provides an incredibly useful tool for configuring and managing multiple ASP.NET applications on a single server.

Enhanced Configuration API''s

you can also retrieve and edit configuration information using the system.configuration.configuration class. These API''s let you programmatically access XML configuration files. This lets you to develop custom administration tools. The following code displays the type of authentication enabled for an application on your local machine:

// C#

Configuration cfg = Configuration.GetConfigurationForUrl("/Application_name"); Response.Write( cfg.Web.Authentication.Mode.ToString() );

microsoft Visual Basic .NET

Dim cfg As Configuration =   Configuration.GetConfigurationForUrl("/Application_name") Response.Write( cfg.Web.Authentication.Mode.ToString() )

the following code enables Forms-based authentication for a local Web application:

// C#

Configuration cfg = Configuration.GetConfigurationForUrl("/MyApp"); cfg.Web.Authentication.Mode = HttpAuthenticationMode.Forms; cfg.Update(); 

visual Basic .NET

Dim cfg As Configuration = & _  Configuration.GetConfigurationForUrl("/MyApp") cfg.Web.Authentication.Mode = HttpAuthenticationMode.Forms cfg.Update()

all four of these features (IntelliSense , administrative Web site, MMC snap-in and configuration API''s) help reduce the amount of time and effort you will have to spend configuring your ASP.NET applications.

Changes in Development

asp.net 2.0 and Visual Studio 2005 also change many of the day-to-day aspects of Web application development. In this section, we will look at several of the areas where features available in ASP.NET 1.x have been heavily modified.

Connecting to the Server

in ASP.NET 1.x and older versions of Visual Studio .NET, you had to connect to an IIS instance through Microsoft Front Page Server Extensions. As a developer, you also had to have administrative access to an IIS instance in order to create new Web sites. Many companies were leery of the administrative burden of creating, monitoring, updating, and maintaining extra Web servers running inside the corporate network. In ASP.NET 2.0, connecting to the server has changed.

The Development Server

first, for development, Visual Studio 2005 now comes with a built-in development-only Web server. This lightweight Web server can only respond to local requests and is therefore not a security threat. The server does, however, support full debugging f

网学推荐

免费论文

原创论文

设为首页 | 加入收藏 | 论文首页 | 论文专题 | 设计下载 | 网学软件 | 论文模板 | 论文资源 | 程序设计 | 关于网学 | 站内搜索 | 网学留言 | 友情链接 | 资料中心
版权所有 QQ:3710167 邮箱:3710167@qq.com 网学网 [Myeducs.cn] 您电脑的分辨率是 像素
Copyright 2008-2015 myeducs.Cn www.myeducs.Cn All Rights Reserved 湘ICP备09003080号