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

📄 defineerrorpage.aspx

📁 《圣殿祭司的ASP.NET 2.0开发详解——使用C#》光盘内容.包含了书籍所含的源代码.非常经典的一本asp.net2.0的书籍
💻 ASPX
📖 第 1 页 / 共 2 页
字号:
        if (selectedNode != null) {
            selectedNode.Selected = false;
        }

        PagesTreeView.CollapseAll();
        WarningTable.Visible = false;
        ToggleSettingErrorPageElements(false);
    }
    else {
        ToggleSettingErrorPageElements(true);
    }

    if (IsErrorModeOff()) {
        WarningTable2.Visible = true;
    } else {
        WarningTable2.Visible = false;
    }
}

// Confirmation's related handlers
void ConfirmOK_Click(object sender, EventArgs e) {
    ReturnToPreviousPage(sender, e);
}

</script>

<%-- Main Content --%>
<asp:content runat="server" contentplaceholderid="titleBar">
    <asp:Label runat="server" id="DefineErrorPageTitle" Text="<%$ Resources:Title %>"/>
</asp:content>

<asp:content runat="server" contentplaceholderid="content">
    <table height="100%" width="90%" cellspacing="0" cellpadding="0">
        <tr class="bodyTextNoPadding">
            <td>
                <asp:Literal runat="server" Text="<%$ Resources:Instructions %>"/>
            </td>
        </tr>
        
        <tr>
            <td>
                &nbsp;
            </td>
        </tr>
        
        <tr>
            <td>
                <table runat="server" id="WarningTable2" width="100%" valign="top" Visible="false">
                    <tr class="bodyText" valign="top">
                        <td>
                            <asp:Image runat="server" id="Alert2" ImageUrl="~/images/alert_lrg.gif"/>
                        </td>
                        <td/>
                        <td>
                            <asp:Label runat=server id="WarningLabel2" ForeColor="maroon" Text="<%$ Resources:ErrorPageWarningErrorsNotEnabled %>"/>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        
        <tr>
            <td>
                <table cellspacing="0" height="100%" width="100%" cellpadding="0" rules="all"
                    bordercolor="#CCDDEF" border="1" style="border-color:#CCDDEF;border-style:None;border-collapse:collapse;" >
                    <tr class="bodyText" valign="top">
                        <td>
                            <table cellspacing="0" height="100%" width="100%" cellpadding="4" rules="all" 
                                border="0" style="border-style:None;border-collapse:collapse;">
                                <tr class="bodyText" valign="top">
                                    <td style="padding-left:10;padding-right:10;">
                                        <asp:RadioButton runat="server" id="DefaultErrorRadioButton" groupName="ErrorSelection" AutoPostBack="true" OnCheckedChanged="WebControl_ValueChanged"/>
                                    </td>
                                    <td style="padding-right:10;">
                                        <asp:Label runat="server" AssociatedControlID="DefaultErrorRadioButton" Text="<%$ Resources:DefaultErrorLabel %>" Font-Bold="true"/>
                                    </td>
                                </tr>
                                <tr class="bodyText" valign="top">
                                    <td style="padding-left:10;padding-right:10;">
                                        <asp:RadioButton runat="server" id="ErrorPageRadioButton" groupName="ErrorSelection" AutoPostBack="true" OnCheckedChanged="WebControl_ValueChanged"/>
                                    </td>
                                    <td style="padding-right:10;">
                                        <asp:Label runat="server" AssociatedControlID="ErrorPageRadioButton" Text="<%$ Resources:ErrorPageLabel %>" Font-Bold="true"/>
                                    </td>
                                </tr>
                                <tr class="bodyText" valign="top">
                                    <td/>
                                    <td style="padding-right:10;">
                                        <asp:Literal runat="server" Text="<%$ Resources:ErrorPageInstructions %>"/>
                                    </td>
                                </tr>
                                <tr class="bodyText" valign="top">
                                    <td/>
                                    <td style="padding-right:10;">
                                        <table runat="server" id="WarningTable" width="100%" valign="top" Visible="false">
                                            <tr class="bodyText" valign="top">
                                                <td>
                                                    <asp:Image runat="server" id="Alert" ImageUrl="~/images/alert_lrg.gif"/>
                                                </td>
                                                <td/>
                                                <td>
                                                    <asp:Label runat=server id="WarningLabel" ForeColor="maroon" Text="<%$ Resources:ErrorPageWarningLabel %>"/>
                                                    <asp:Label runat=server id="WarningErrorPageUrlLabel" ForeColor="maroon" Font-Bold="true"/>
                                                </td>
                                            </tr>
                                        </table>
                                    </td>
                                </tr>
                                <tr>
                                    <td/>
                                    <td>
                                        <table cellspacing="0" height="100%" width="600" cellpadding="0" rules="none"
                                            bordercolor="#CCDDEF" border="1" style="border-color:#CCDDEF;border-style:None;border-collapse:collapse;">
                                            <tr class="callOutStyle">
                                                <td style="padding-top:4;padding-left:10;padding-right:10;padding-bottom:4;" colspan="2">
                                                    <asp:Literal runat="server" Text="<%$ Resources:SelectCustomErrorPageTitle %>"/>
                                                </td>
                                            </tr>
                                            <tr class="bodyText" style="padding-top:0;">
                                                <td style="padding-left:0;padding-right:0;" colspan="2">
                                                    <asp:panel id="PagesPanel" runat="server" scrollbars="both" height="200" width="600" cssclass="bodyTextNoPadding">
                                                        <asp:treeView runat="server" id="PagesTreeView" >
                                                            <RootNodeStyle ImageUrl="../images/folder.gif" />
                                                            <ParentNodeStyle ImageUrl="../images/folder.gif" />
                                                            <LeafNodeStyle ImageUrl="../images/folder.gif" />
                                                            <nodestyle cssClass="bodyTextLowPadding"/>
                                                            <selectedNodeStyle cssClass="bodyTextLowPaddingSelected"/>
                                                        </asp:treeView>
                                                    </asp:panel>
                                                </td>
                                            </tr>
                                        </table>
                                    </td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                    
                    <tr>
                        <td>
                            <table cellspacing="0" height="100%" width="100%" cellpadding="0" rules="all" 
                                border="0" style="border-style:None;border-collapse:collapse;">

                                <tr class="userDetailsWithFontSize" valign="top">
                                    <td style="padding-left:10;padding-right:10;" align="left">
                                        <asp:ValidationSummary runat="server" HeaderText="<%$ Resources:GlobalResources,ErrorHeader %>" ValidationGroup="SetErrorPage"/>
                                        <asp:CustomValidator runat="server" EnableClientScript="false" Display="none"
                                            ValidationGroup="SetErrorPage" OnServerValidate="ErrorPage_ServerValidate"
                                            ErrorMessage="<%$ Resources:ErrorPageNotSetError %>"/>
                                    </td>
                                    <td style="padding-left:10;padding-right:10;" align="right" width="1%">
                                        <asp:Button id="SaveButton" runat="server" Text="<%$ Resources:GlobalResources,SaveButtonLabel %>" OnClick="SaveButton_Click"
                                            ValidationGroup="SetErrorPage" width="100"/>
                                    </td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        
        <tr height="100%">
            <td/>
        </tr>
        
    </table>
</asp:content>

<asp:content runat="server" contentplaceholderid="buttons">
    <asp:button ValidationGroup="none" text="<%$ Resources:GlobalResources,BackButtonLabel %>" id="BackButton" onclick="ReturnToPreviousPage" runat="server"/>
</asp:content>

<%-- Confirmation Dialog --%>
<asp:content runat="server" contentplaceholderid="dialogTitle">
    <asp:Literal runat="server" Text="<%$ Resources:Title %>"/>
</asp:content>

<asp:content runat="server" contentplaceholderid="dialogContent">
    <table cellspacing="4" cellpadding="4">
        <tr class="bodyText">
            <td>
                <asp:Literal runat="server" Text="<%$ Resources:ConfirmationText %>"/>
            </td>
        </tr>
    </table>
</asp:content>

<asp:content runat="server" contentplaceholderid="dialogBottomLeftLink">
    <asp:HyperLink runat="server" NavigateUrl="AppConfigHome.aspx" Text="<%$ Resources:AppConfigCommon,AppConfigHomeLinkText %>"/>
</asp:content>

<asp:content runat="server" contentplaceholderid="dialogBottomRightButton">
    <asp:Button runat="server" OnClick="ConfirmOK_Click" Text="<%$ Resources:GlobalResources,OKButtonLabel %>" width="75"/>
</asp:content>

⌨️ 快捷键说明

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