⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wizardproviderinfo.ascx

📁 《圣殿祭司的ASP.NET 2.0开发详解——使用C#》光盘内容.包含了书籍所含的源代码.非常经典的一本asp.net2.0的书籍
💻 ASCX
字号:
<%@ Control Inherits="System.Web.Administration.WebAdminUserControl" %>
<%@ Import Namespace="System.Web.Administration" %>
<%@ Import Namespace="System.Web.Configuration" %>


<script runat="server" language="cs">
private string ApplicationPath {
    get {
        return (string)Session["WebAdminApplicationPath"];
    }
}

public void Page_Load() {
    System.Configuration.Configuration config = ((WebAdminPage)Page).OpenWebConfiguration(ApplicationPath);
    MembershipSection membershipSection = (MembershipSection)config.GetSection("system.web/membership");
    RoleManagerSection roleManagerSection = (RoleManagerSection)config.GetSection("system.web/roleManager");
    ConnectionStringsSection connectionStringSection = (ConnectionStringsSection)config.GetSection("connectionStrings");

    string defaultProvider = membershipSection.DefaultProvider;
    string connectionStringName = membershipSection.Providers[defaultProvider].Parameters["connectionStringName"];
    if (defaultProvider == roleManagerSection.DefaultProvider &&
        connectionStringName == roleManagerSection.Providers[defaultProvider].Parameters["connectionStringName"]) {
        label1.Text = defaultProvider;
    }
    else {
        label1.Text = (string)GetLocalResourceObject("AdvancedSettings"); 
    }

}
</script>

<table border="0" cellpadding="0" cellspacing="0" width="100%" >
<tr><td class="bodyTextLeftPadding5">
<asp:literal runat="server" text="<%$ Resources:CurrentlyConfigured %>" />
<br/><br/>

<asp:label runat="server" id="label1" font-bold="true" text="Unknown"/>

<br/><br/>
<asp:literal runat="server" text="<%$ Resources:ChangeInstructions %>"/>
</td></tr></table>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -