ASP.NET Page /UserLogin/CompletePasswordReset.aspx (C#)
Uses Code Behind Page Page /UserLogin/CompletePasswordReset.aspx.cs (C#)
1: <%@ Page Language="C#" MasterPageFile="~/Master/MasterPage.master" AutoEventWireup="true" Inherits="CompletePasswordReset" Title="Untitled Page" Codebehind="CompletePasswordReset.aspx.cs" %>  
2: <%@ MasterType VirtualPath="~/Master/MasterPage.master" %>  
3: <asp:Content ID="Content1" ContentPlaceHolderID="MainContentPlaceHolder" runat="server">  
4:     <center>  
5:    <asp:ChangePassword ID="ChangePasswordCtrl" runat="server" CssClass="Content_Table" ConfirmNewPasswordLabelText="Confirm new password:" NewPasswordLabelText="New password:" ConfirmPasswordCompareErrorMessage="The password confirmation must match the new password entry." ConfirmPasswordRequiredErrorMessage="New password confirmation is required." ContinueDestinationPageUrl="~/default.aspx" CancelDestinationPageUrl="~/Login.aspx" ContinueButtonText="Login" OnChangingPassword="ChangePasswordCtrl_ChangingPassword">  
6:       <LabelStyle HorizontalAlign="Left" Wrap="False" />  
7:       <TitleTextStyle CssClass="sectionHeader" Wrap="False" />  
8:       <FailureTextStyle HorizontalAlign="Left" />  
9:       <SuccessTextStyle HorizontalAlign="Left" />  
10:       <ChangePasswordTemplate>  
11:          <table border="0" cellpadding="1" cellspacing="0" style="border: Gray 1px solid" >  
12:             <tr>  
13:                <td>  
14:                   <table border="0" cellpadding="0">  
15:                      <tr>  
16:                         <td align="center" colspan="2" class="sectionHeader" style="whitespace:nowrap">  
17:                            Reset Your Password</td>  
18:                      </tr>  
19:                      <tr>  
20:                         <td align="left" style="white-space: nowrap">  
21:                            <asp:TextBox ID="CurrentPassword" runat="server" TextMode="Password" Visible="false"></asp:TextBox>  
22:                         </td>  
23:                      </tr>  
24:                      <tr>  
25:                         <td align="left" style="white-space: nowrap">  
26:                            <asp:Label ID="NewPasswordLabel" runat="server" AssociatedControlID="NewPassword">New password:</asp:Label></td>  
27:                         <td>  
28:                            <asp:TextBox ID="NewPassword" runat="server" TextMode="Password"></asp:TextBox>  
29:                            <asp:RequiredFieldValidator ID="NewPasswordRequired" runat="server" ControlToValidate="NewPassword" ErrorMessage="New Password is required." ToolTip="New Password is required." ValidationGroup="ChangePasswordCtrl">*</asp:RequiredFieldValidator>  
30:                         </td>  
31:                      </tr>  
32:                      <tr>  
33:                         <td align="left" style="white-space: nowrap">  
34:                            <asp:Label ID="ConfirmNewPasswordLabel" runat="server" AssociatedControlID="ConfirmNewPassword">Confirm new password:</asp:Label></td>  
35:                         <td>  
36:                            <asp:TextBox ID="ConfirmNewPassword" runat="server" TextMode="Password"></asp:TextBox>  
37:                            <asp:RequiredFieldValidator ID="ConfirmNewPasswordRequired" runat="server" ControlToValidate="ConfirmNewPassword" ErrorMessage="New password confirmation is required." ToolTip="New password confirmation is required." ValidationGroup="ChangePasswordCtrl">*</asp:RequiredFieldValidator>  
38:                         </td>  
39:                      </tr>  
40:                      <tr>  
41:                         <td align="center" colspan="2">  
42:                            <asp:CompareValidator ID="NewPasswordCompare" runat="server" ControlToCompare="NewPassword" ControlToValidate="ConfirmNewPassword" Display="Dynamic" ErrorMessage="The password confirmation must match the new password entry." ValidationGroup="ChangePasswordCtrl"></asp:CompareValidator>  
43:                         </td>  
44:                      </tr>  
45:                      <tr>  
46:                         <td align="left" colspan="2" style="color: red">  
47:                            <asp:Literal ID="FailureText" runat="server" EnableViewState="False"></asp:Literal>  
48:                         </td>  
49:                      </tr>  
50:                      <tr>  
51:                         <td align="right">  
52:                            <asp:Button ID="ChangePasswordPushButton" runat="server" CommandName="ChangePassword" Text="Change Password" ValidationGroup="ChangePasswordCtrl" />  
53:                         </td>  
54:                         <td>  
55:                            <asp:Button ID="CancelPushButton" runat="server" CausesValidation="False" CommandName="Cancel" Text="Cancel" />  
56:                         </td>  
57:                      </tr>  
58:                   </table>  
59:                </td>  
60:             </tr>  
61:          </table>  
62:       </ChangePasswordTemplate>  
63:       <SuccessTemplate>  
64:          <table border="0" cellpadding="1" cellspacing="0">  
65:             <tr>  
66:                <td>  
67:                   <table border="0" cellpadding="0">  
68:                      <tr>  
69:                         <td align="center" colspan="2" class="sectionHeader" style="whitespace: nowrap">  
70:                            Reset Password Complete</td>  
71:                      </tr>  
72:                      <tr>  
73:                         <td align="left" style="padding-top:2ex; padding-bottom:2ex">  
74:                            Your password has been reset!<br />  
75:                         </td>  
76:                      </tr>  
77:                      <tr>  
78:                         <td align="center" colspan="2">  
79:                            <asp:Button ID="ContinuePushButton" runat="server" CausesValidation="False" CommandName="Continue" Text="Continue" />  
80:                         </td>  
81:                      </tr>  
82:                   </table>  
83:                </td>  
84:             </tr>  
85:          </table>  
86:       </SuccessTemplate>  
87:    </asp:ChangePassword>  
88: </asp:Content>  

.NET Documentation Tool is © 2002 - 2009 Winnersh Triangle Web Solutions Limited.