Solved

ASP.NET page with multiple submit buttons does not submit

Posted on 2008-10-26
17
1,123 Views
Last Modified: 2012-08-13
I have made an edit profile page in asp.net.

It has 2 parts - change password and change email address.

both have submit buttons and validator controls to check whether the fields have been left blank.
(requiredfieldvalidator)


The problem is - on pressing enter which changing password, the validators of email gets displayed (password field cannot be left empty). However, if i try changing the password using mouse (click on the submit button) then it works fine.


Changing email works with enter as well as mouse click (the change password validators dont get trigerred)

Please help me and tell me what i'm doing wrong here
0
Comment
Question by:the_7th_king
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 8
  • 8
17 Comments
 
LVL 20

Expert Comment

by:Juan_Barrera
ID: 22810320
I think that you are not setting the default button for each panel containing your buttons, like:

<asp:Panel ID="Panel1" runat="server" defaultbutton="Button1">
                 <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
                 <asp:Button ID="Button1" runat="server" Text="Button1"  />
</asp:Panel>
In this way, when typing on any of the controls inside the panel, the default form submit button will change to the one that is specified in the defaultbutton property.
0
 
LVL 2

Author Comment

by:the_7th_king
ID: 22810422
that didn't work
0
 
LVL 20

Expert Comment

by:Juan_Barrera
ID: 22810429
Can you post your markup please?
The behaviour you are experiencing is due to the forms "defaultButton" property.
0
MS Dynamics Made Instantly Simpler

Make Your Microsoft Dynamics Investment Count  & Drastically Decrease Training Time by Providing Intuitive Step-By-Step WalkThru Tutorials.

 
LVL 20

Expert Comment

by:Juan_Barrera
ID: 22810445
Have a look at this link, maybe it helps:
http://geekswithblogs.net/ranganh/archive/2006/04/12/74951.aspx
 
0
 
LVL 2

Author Comment

by:the_7th_king
ID: 22810474


<form id="form1" runat="server">
    <div>
        <table border ="0" cellpadding ="0" cellspacing ="0" width ="100%" style="height: 50px" id="TABLE2">
       <tr>
       <td style="height: 19px;" colspan="2">
      <uc1:TopBanner ID="topbanner1" runat="server">
    </uc1:TopBanner>
   
    </td> 
       </tr>
          <tr>
              <td colspan="3" rowspan="4" style="width: 932px; height: 19px">
        
         <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/ControlPanel.aspx" Style="left: 15px;
                      position: relative; top: 0px">Control Panel</asp:HyperLink>
         <asp:HyperLink ID="HyperLink2" runat="server" NavigateUrl="Logout.aspx" Style="left: 839px;
            position: relative; top: 1px">Logout</asp:HyperLink></td> </tr>
          <tr>
          </tr>
          <tr>
          </tr>
          <tr>
          </tr>
        </table>
        <br />
        <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
        &nbsp;
            
            <asp:Panel ID="Panel1" runat="server" Height="200px" Width="636px" BackColor="#B6D31E" style="left: 84px; position: relative; top: 0px">
            
         <asp:ChangePassword ID="ChangePassword1" runat="server" style="left: 41px; position: relative; top: 4px" CancelDestinationPageUrl="~/ControlPanel.aspx" ContinueDestinationPageUrl="~/ControlPanel.aspx" Height="1px" Width="499px">
            <ChangePasswordTemplate>
                <table border="0" cellpadding="1" cellspacing="0" style="border-collapse: collapse; width: 499px; height: 183px;" id="TABLE1">
                    <tr>
                        <td style="height: 190px; width: 462px;">
                            <table border="0" cellpadding="0" style="left: 3px; position: relative; top: 13px; width: 496px; height: 140px;">
                                <tr>
                                    <td align="center" colspan="2" style="height: 19px">
                                        <strong>&nbsp; 
                                            <asp:Label ID="Label1" runat="server" Style="left: 0px; position: relative; top: -17px"
                                                Text="Change Password "></asp:Label></strong></td>
                                </tr>
                                <tr>
                                    <td align="right" colspan="2" style="height: 24px">
                                        <asp:Label ID="CurrentPasswordLabel" runat="server" AssociatedControlID="CurrentPassword" style="left: -172px; position: relative; top: 0px">Current Password:</asp:Label>
                                        <asp:RequiredFieldValidator ID="CurrentPasswordRequired" runat="server" ControlToValidate="CurrentPassword"
                                            ErrorMessage="Password is required." ToolTip="Password is required." ValidationGroup="ChangePassword1" style="left: 9px; position: relative" Display="Dynamic">*</asp:RequiredFieldValidator>
                                    <asp:TextBox ID="CurrentPassword" runat="server" TextMode="Password" style="left: -158px; position: relative; top: 0px"></asp:TextBox>&nbsp;
                                    <cc1:FilteredTextBoxExtender ID="FilteredTextBoxExtender1" runat="server" TargetControlID="CurrentPassword" FilterType="Custom" FilterMode="InvalidChars" InvalidChars="/*-+;'?, :{}.<>;$@!`&=\(~^)[]|%#" FilterInterval="2">
        </cc1:FilteredTextBoxExtender>
                                    </td>
                                </tr>
                                <tr>
                                    <td align="right" style="height: 23px;" colspan="2">
                                        <asp:Label ID="NewPasswordLabel" runat="server" AssociatedControlID="NewPassword" style="left: -171px; position: relative; top: 0px">New Password:</asp:Label>
                                        <asp:RequiredFieldValidator ID="NewPasswordRequired" runat="server" ControlToValidate="NewPassword"
                                            ErrorMessage="New Password is required." ToolTip="New Password is required."
                                            ValidationGroup="ChangePassword1" style="left: 12px; position: relative" Display="Dynamic">*</asp:RequiredFieldValidator>
                                    <asp:TextBox ID="NewPassword" runat="server" TextMode="Password" style="left: -155px; position: relative; top: 0px"></asp:TextBox>
                                    <cc1:FilteredTextBoxExtender ID="FilteredTextBoxExtender2" runat="server" TargetControlID="NewPassword" FilterType="Custom" FilterMode="InvalidChars" InvalidChars="/*-+;'?, :{}.<>;$@!`&=\(~^)[]|%#" FilterInterval="2">
        </cc1:FilteredTextBoxExtender>
                                    &nbsp;
                                    </td>
                                </tr>
                                <tr>
                                    <td align="right" style="height: 24px;" colspan="2">
                                        <asp:Label ID="ConfirmNewPasswordLabel" runat="server" AssociatedControlID="ConfirmNewPassword" style="left: -170px; position: relative; top: 0px">Confirm New Password:</asp:Label>
                                        <asp:RequiredFieldValidator ID="ConfirmNewPasswordRequired" runat="server" ControlToValidate="ConfirmNewPassword"
                                            ErrorMessage="Confirm New Password is required." ToolTip="Confirm New Password is required."
                                            ValidationGroup="ChangePassword1" style="left: 12px; position: relative" Display="Dynamic">*</asp:RequiredFieldValidator>
                                    <asp:TextBox ID="ConfirmNewPassword" runat="server" TextMode="Password" style="left: -155px; position: relative; top: 0px"></asp:TextBox>
                                    <cc1:FilteredTextBoxExtender ID="FilteredTextBoxExtender3" runat="server" TargetControlID="ConfirmNewPassword" FilterType="Custom" FilterMode="InvalidChars" InvalidChars="/*-+;'?, :{}.<>;$@!`&=\(~^)[]|%#" FilterInterval="2">
        </cc1:FilteredTextBoxExtender>
                                    &nbsp;
                                    </td>
                                </tr>
                                <tr>
                                    <td align="center" colspan="2">
                                        <asp:CompareValidator ID="NewPasswordCompare" runat="server" ControlToCompare="NewPassword"
                                            ControlToValidate="ConfirmNewPassword" Display="Dynamic" ErrorMessage="The Confirm New Password must match the New Password entry."
                                            ValidationGroup="ChangePassword1"></asp:CompareValidator>
                                    </td>
                                </tr>
                                <tr>
                                    <td align="center" colspan="2" style="color: red; height: 16px;">
                                        <asp:Literal ID="FailureText" runat="server" EnableViewState="False"></asp:Literal>
                                    </td>
                                </tr>
                                <tr>
                                    <td align="right" style="height: 24px; width: 315px;">
                                        &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
                                        &nbsp;&nbsp;
                                        <asp:Button ID="ResetButton" runat="server" Text="Reset" style="left: 43px; position: relative; top: 0px;" OnClientClick="reset()" CausesValidation="False" UseSubmitBehavior="False"  /><asp:Button ID="ChangePasswordPushButton" runat="server" CommandName="ChangePassword"
                                            Text="Save" ValidationGroup="ChangePassword1" OnClick="ChangePasswordPushButton_Click" style="left: 120px; top: 0px; position: relative;" Width="56px" /><asp:Button ID="CancelPushButton" runat="server" CausesValidation="False" CommandName="Cancel"
                                            Text="Cancel" style="left: -4px; top: 0px; position: relative;" OnClick="CancelPushButton_Click" />&nbsp;</td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                </table>
            </ChangePasswordTemplate>
        </asp:ChangePassword>
           &nbsp;
 </asp:Panel>
 <cc1:RoundedCornersExtender ID="RoundedCornersExtender1" runat="server" Corners ="All" Radius ="20" TargetControlID="Panel1">
            </cc1:RoundedCornersExtender>
        <br />
        
        
            <asp:Panel ID="Panel2" runat="server" Height="143px" Width="636px" BackColor="#3E4895" style="left: 84px; position: relative; top: 6px">
            
        <table style="left: 19px; width: 613px; position: relative; top: 10px; height: 1px">
            <tr>
                <td colspan="4" style="height: 15px; text-align: left">
                    <strong><span style="color: #ffffff">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
                        &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
                        &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; Change E-mail Address</span></strong></td>
            </tr>
            <tr>
                <td colspan="3" style="width: 120px; height: 49px">
    <asp:Label ID="Label2" runat="server" Style="left: 32px; position: relative; top: 11px"
        Text="New E-Mail Address: " Width="139px" ForeColor="White"></asp:Label></td>
                <td style="width: 402px; height: 49px">
        <asp:TextBox ID="newemail" runat="server" TextMode="SingleLine" style="left: 4px; position: relative; top:12px"></asp:TextBox>
        <cc1:FilteredTextBoxExtender ID="FilteredTextBoxExtender4" runat="server" TargetControlID="newemail" FilterType="Custom" FilterMode="InvalidChars" InvalidChars="/*-+;'?, :{}<>;$!`&=\(~^)[]|%#" FilterInterval="2">
        </cc1:FilteredTextBoxExtender>
    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="newemail"
        ErrorMessage="Please enter an e-mail address" Style="left: 20px; position: relative;
        top: 12px" Font-Bold="False"></asp:RequiredFieldValidator></td>
            </tr>
                <tr>
                <td colspan="3" style="width: 120px; height: 22px">
 
    <asp:Label ID="Label3" runat="server" Style="left: -16px; position: relative; top: 0px"
        Text="Confirm New E-Mail Address: " Width="187px" ForeColor="White"></asp:Label></td>
                <td style="width: 402px; height: 22px">
        <asp:TextBox ID="newemail1" runat="server" TextMode="SingleLine" style="left: 4px; position: relative; top:0px"></asp:TextBox>
                <cc1:FilteredTextBoxExtender ID="FilteredTextBoxExtender5" runat="server" TargetControlID="newemail1" FilterType="Custom" FilterMode="InvalidChars" InvalidChars="/*-+;'?, :{}<>;$!`&=\(~^)[]|%#" FilterInterval="2">
        </cc1:FilteredTextBoxExtender>&nbsp;
    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="newemail1"
        ErrorMessage="Please confirm the e-mail address" Style="left: 15px; position: relative;
        top: -2px" Font-Bold="False"></asp:RequiredFieldValidator></td>
            </tr>
            <tr>
                <td colspan="3" style="width: 120px; height: 11px">
                </td>
                <td style="width: 402px; height: 11px">
                </td>
            </tr>
            <tr>
                <td colspan="3" style="width: 120px; height: 12px">
    <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="newemail"
        ControlToValidate="newemail1" ErrorMessage="E-mail addresses don't match" Style="left: 197px;
        position: relative; top: -97px" Font-Bold="False" Width="181px"></asp:CompareValidator></td>
                <td style="width: 402px; height: 12px">
        <asp:Button ID="cancelmail" runat="server" Text="Cancel" style="left: 4px; position: relative; top: 0px" CausesValidation="False" CommandName="Cancel" OnClick="cancelmail_Click" UseSubmitBehavior="False" />
                    <asp:Button ID="changemail" runat="server" Text="Save" style="left: 18px; position: relative; top: 0px" OnClick="changemail_Click" Width="56px" /></td>
            </tr>
                      </table>
        </asp:Panel>
            <cc1:RoundedCornersExtender ID="RoundedCornersExtender2" runat="server" Radius ="20" Corners ="All" TargetControlID="Panel2">
            </cc1:RoundedCornersExtender>
            <br />
    <ff1:Footer ID="Footer1" runat="server" />
    
        </div>  
    </form>

Open in new window

0
 
LVL 20

Expert Comment

by:Juan_Barrera
ID: 22810523
It does work for me if I add the following property to the Panel with ID Panel1: DefaultButton="ChangePasswordPushButton"
However, I moved the button out of the ChangePasswordTemplate to be able to map the server ID "Button1". If you want to keep the same layout, you need to find the actual UniqueID of the button and set the property accordingly (code-behind would be the easiest)
0
 
LVL 2

Author Comment

by:the_7th_king
ID: 22810531
i tried doing defaultbutton for panel1 as "changepasswordpushbutton" but it gave me a runtime error


i do not understand what you said about uniqueid

please pardon my ignorance and help me
0
 
LVL 20

Expert Comment

by:Juan_Barrera
ID: 22810548
The runtime error you get is because the Button1 is inside the ChangePasswordTemplate, which acts as a naming container for controls. Therefore, at runtime, ASP.NET is unable to resolve the ID set in defaultButton, because it's kind of "hidden" inside the template.  
Try putting Button1 outside the ChangePasswordTemplate and see if it works. Then, if it does, we can try to do the "code-behind' thing, to work around the runtime issue.
0
 
LVL 2

Author Comment

by:the_7th_king
ID: 22810724
so i add a new button as a default button and in its code behind, i call the actual changepasswordpushbutton?
0
 
LVL 20

Expert Comment

by:Juan_Barrera
ID: 22810781
You can do it even easier: Just surround your whole Template content with a new Panel, and use it to set the property. See how, in this case, the fact that the Panel is inside the template allows the runtime to properly discover the ID.

<ChangePasswordTemplate>
      <asp:Panel runat="server" DefaultButton="changepasswordpushbutton">
                <Your markup>
     
      </asp:Panel>
</ChangePasswordTemplate>
 
0
 
LVL 2

Author Comment

by:the_7th_king
ID: 22810798
i did as you suggested above
the run time error still persists
0
 
LVL 20

Accepted Solution

by:
Juan_Barrera earned 100 total points
ID: 22810814
It works for me. I've just added a Panel under ChangePasswordTemplate. Can you please try by copying the following code?

    <form id="form1" runat="server">
    <div>
        <table border="0" cellpadding="0" cellspacing="0" width="100%" style="height: 50px"
            id="TABLE2">
            <tr>
                <td style="height: 19px;" colspan="2">
                    <uc1:topbanner id="topbanner1" runat="server">
    </uc1:topbanner>
                </td>
            </tr>
            <tr>
                <td colspan="3" rowspan="4" style="width: 932px; height: 19px">
                    <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/ControlPanel.aspx" Style="left: 15px;
                        position: relative; top: 0px">Control Panel</asp:HyperLink>
                    <asp:HyperLink ID="HyperLink2" runat="server" NavigateUrl="Logout.aspx" Style="left: 839px;
                        position: relative; top: 1px">Logout</asp:HyperLink>
                </td>
            </tr>
            <tr>
            </tr>
            <tr>
            </tr>
            <tr>
            </tr>
        </table>
        <br />
        <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
        &nbsp;
        <asp:Panel ID="Panel1" runat="server" Height="200px" Width="636px" BackColor="#B6D31E"
            Style="left: 84px; position: relative; top: 0px">
            <asp:ChangePassword ID="ChangePassword1" runat="server" Style="left: 41px; position: relative;
                top: 4px" CancelDestinationPageUrl="~/ControlPanel.aspx" ContinueDestinationPageUrl="~/ControlPanel.aspx"
                Height="1px" Width="499px">
                <ChangePasswordTemplate>
                <asp:Panel runat=server DefaultButton="ChangePasswordPushButton" >
                    <table border="0" cellpadding="1" cellspacing="0" style="border-collapse: collapse;
                        width: 499px; height: 183px;" id="TABLE1">
                        <tr>
                            <td style="height: 190px; width: 462px;">
                                <table border="0" cellpadding="0" style="left: 3px; position: relative; top: 13px;
                                    width: 496px; height: 140px;">
                                    <tr>
                                        <td align="center" colspan="2" style="height: 19px">
                                            <strong>&nbsp;
                                                <asp:Label ID="Label1" runat="server" Style="left: 0px; position: relative; top: -17px"
                                                    Text="Change Password "></asp:Label></strong>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="right" colspan="2" style="height: 24px">
                                            <asp:Label ID="CurrentPasswordLabel" runat="server" AssociatedControlID="CurrentPassword"
                                                Style="left: -172px; position: relative; top: 0px">Current Password:</asp:Label>
                                            <asp:RequiredFieldValidator ID="CurrentPasswordRequired" runat="server" ControlToValidate="CurrentPassword"
                                                ErrorMessage="Password is required." ToolTip="Password is required." ValidationGroup="ChangePassword1"
                                                Style="left: 9px; position: relative" Display="Dynamic">*</asp:RequiredFieldValidator>
                                            <asp:TextBox ID="CurrentPassword" runat="server" TextMode="Password" Style="left: -158px;
                                                position: relative; top: 0px"></asp:TextBox>&nbsp;
                                            <cc1:filteredtextboxextender id="FilteredTextBoxExtender1" runat="server" targetcontrolid="CurrentPassword"
                                                filtertype="Custom" filtermode="InvalidChars" invalidchars="/*-+;'?, :{}.<>;$@!`&=\(~^)[]|%#"
                                                filterinterval="2">
        </cc1:filteredtextboxextender>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="right" style="height: 23px;" colspan="2">
                                            <asp:Label ID="NewPasswordLabel" runat="server" AssociatedControlID="NewPassword"
                                                Style="left: -171px; position: relative; top: 0px">New Password:</asp:Label>
                                            <asp:RequiredFieldValidator ID="NewPasswordRequired" runat="server" ControlToValidate="NewPassword"
                                                ErrorMessage="New Password is required." ToolTip="New Password is required."
                                                ValidationGroup="ChangePassword1" Style="left: 12px; position: relative" Display="Dynamic">*</asp:RequiredFieldValidator>
                                            <asp:TextBox ID="NewPassword" runat="server" TextMode="Password" Style="left: -155px;
                                                position: relative; top: 0px"></asp:TextBox>
                                            <cc1:filteredtextboxextender id="FilteredTextBoxExtender2" runat="server" targetcontrolid="NewPassword"
                                                filtertype="Custom" filtermode="InvalidChars" invalidchars="/*-+;'?, :{}.<>;$@!`&=\(~^)[]|%#"
                                                filterinterval="2">
        </cc1:filteredtextboxextender>
                                            &nbsp;
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="right" style="height: 24px;" colspan="2">
                                            <asp:Label ID="ConfirmNewPasswordLabel" runat="server" AssociatedControlID="ConfirmNewPassword"
                                                Style="left: -170px; position: relative; top: 0px">Confirm New Password:</asp:Label>
                                            <asp:RequiredFieldValidator ID="ConfirmNewPasswordRequired" runat="server" ControlToValidate="ConfirmNewPassword"
                                                ErrorMessage="Confirm New Password is required." ToolTip="Confirm New Password is required."
                                                ValidationGroup="ChangePassword1" Style="left: 12px; position: relative" Display="Dynamic">*</asp:RequiredFieldValidator>
                                            <asp:TextBox ID="ConfirmNewPassword" runat="server" TextMode="Password" Style="left: -155px;
                                                position: relative; top: 0px"></asp:TextBox>
                                            <cc1:filteredtextboxextender id="FilteredTextBoxExtender3" runat="server" targetcontrolid="ConfirmNewPassword"
                                                filtertype="Custom" filtermode="InvalidChars" invalidchars="/*-+;'?, :{}.<>;$@!`&=\(~^)[]|%#"
                                                filterinterval="2">
        </cc1:filteredtextboxextender>
                                            &nbsp;
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="center" colspan="2">
                                            <asp:CompareValidator ID="NewPasswordCompare" runat="server" ControlToCompare="NewPassword"
                                                ControlToValidate="ConfirmNewPassword" Display="Dynamic" ErrorMessage="The Confirm New Password must match the New Password entry."
                                                ValidationGroup="ChangePassword1"></asp:CompareValidator>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="center" colspan="2" style="color: red; height: 16px;">
                                            <asp:Literal ID="FailureText" runat="server" EnableViewState="False"></asp:Literal>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="right" style="height: 24px; width: 315px;">
                                            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
                                            &nbsp;&nbsp;
                                            <asp:Button ID="ResetButton" runat="server" Text="Reset" Style="left: 43px; position: relative;
                                                top: 0px;" OnClientClick="reset()" CausesValidation="False" UseSubmitBehavior="False" /><asp:Button
                                                    ID="ChangePasswordPushButton" runat="server" CommandName="ChangePassword" Text="Save"
                                                    ValidationGroup="ChangePassword1" OnClick="ChangePasswordPushButton_Click" Style="left: 120px;
                                                    top: 0px; position: relative;" Width="56px" /><asp:Button ID="CancelPushButton" runat="server"
                                                        CausesValidation="False" CommandName="Cancel" Text="Cancel" Style="left: -4px;
                                                        top: 0px; position: relative;" OnClick="CancelPushButton_Click" />&nbsp;
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                    </table>
                    </asp:Panel>
                </ChangePasswordTemplate>
            </asp:ChangePassword>
            &nbsp;
        </asp:Panel>
        <cc1:roundedcornersextender id="RoundedCornersExtender1" runat="server" corners="All"
            radius="20" targetcontrolid="Panel1">
            </cc1:roundedcornersextender>
        <br />
        <asp:Panel ID="Panel2" runat="server" Height="143px" Width="636px" BackColor="#3E4895"
            Style="left: 84px; position: relative; top: 6px">
            <table style="left: 19px; width: 613px; position: relative; top: 10px; height: 1px">
                <tr>
                    <td colspan="4" style="height: 15px; text-align: left">
                        <strong><span style="color: #ffffff">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
                            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
                            &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; Change E-mail Address</span></strong>
                    </td>
                </tr>
                <tr>
                    <td colspan="3" style="width: 120px; height: 49px">
                        <asp:Label ID="Label2" runat="server" Style="left: 32px; position: relative; top: 11px"
                            Text="New E-Mail Address: " Width="139px" ForeColor="White"></asp:Label>
                    </td>
                    <td style="width: 402px; height: 49px">
                        <asp:TextBox ID="newemail" runat="server" TextMode="SingleLine" Style="left: 4px;
                            position: relative; top: 12px"></asp:TextBox>
                        <cc1:filteredtextboxextender id="FilteredTextBoxExtender4" runat="server" targetcontrolid="newemail"
                            filtertype="Custom" filtermode="InvalidChars" invalidchars="/*-+;'?, :{}<>;$!`&=\(~^)[]|%#"
                            filterinterval="2">
        </cc1:filteredtextboxextender>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="newemail"
                            ErrorMessage="Please enter an e-mail address" Style="left: 20px; position: relative;
                            top: 12px" Font-Bold="False"></asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td colspan="3" style="width: 120px; height: 22px">
                        <asp:Label ID="Label3" runat="server" Style="left: -16px; position: relative; top: 0px"
                            Text="Confirm New E-Mail Address: " Width="187px" ForeColor="White"></asp:Label>
                    </td>
                    <td style="width: 402px; height: 22px">
                        <asp:TextBox ID="newemail1" runat="server" TextMode="SingleLine" Style="left: 4px;
                            position: relative; top: 0px"></asp:TextBox>
                        <cc1:filteredtextboxextender id="FilteredTextBoxExtender5" runat="server" targetcontrolid="newemail1"
                            filtertype="Custom" filtermode="InvalidChars" invalidchars="/*-+;'?, :{}<>;$!`&=\(~^)[]|%#"
                            filterinterval="2">
        </cc1:filteredtextboxextender>
                        &nbsp;
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="newemail1"
                            ErrorMessage="Please confirm the e-mail address" Style="left: 15px; position: relative;
                            top: -2px" Font-Bold="False"></asp:RequiredFieldValidator>
                    </td>
                </tr>
                <tr>
                    <td colspan="3" style="width: 120px; height: 11px">
                    </td>
                    <td style="width: 402px; height: 11px">
                    </td>
                </tr>
                <tr>
                    <td colspan="3" style="width: 120px; height: 12px">
                        <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="newemail"
                            ControlToValidate="newemail1" ErrorMessage="E-mail addresses don't match" Style="left: 197px;
                            position: relative; top: -97px" Font-Bold="False" Width="181px"></asp:CompareValidator>
                    </td>
                    <td style="width: 402px; height: 12px">
                        <asp:Button ID="cancelmail" runat="server" Text="Cancel" Style="left: 4px; position: relative;
                            top: 0px" CausesValidation="False" CommandName="Cancel" OnClick="cancelmail_Click"
                            UseSubmitBehavior="False" />
                        <asp:Button ID="changemail" runat="server" Text="Save" Style="left: 18px; position: relative;
                            top: 0px" OnClick="changemail_Click" Width="56px" />
                    </td>
                </tr>
            </table>
        </asp:Panel>
        <cc1:roundedcornersextender id="RoundedCornersExtender2" runat="server" radius="20"
            corners="All" targetcontrolid="Panel2">
            </cc1:roundedcornersextender>
        <br />
        <ff1:footer id="Footer1" runat="server" />
    </div>
    </form>

Open in new window

0
 
LVL 2

Author Comment

by:the_7th_king
ID: 22810870
IT WORKED!

no idea why
i had done the same thing earlier


thanks a TON!
0
 
LVL 2

Author Closing Comment

by:the_7th_king
ID: 31510198
excellent support

thanks!
0
 
LVL 20

Expert Comment

by:Juan_Barrera
ID: 22810876
I'm glad it helped!
Cheers,
0
 
LVL 2

Author Comment

by:the_7th_king
ID: 22810893
you put panel --> template --> panel

and the innermost panel shares its ID with other panel, too

why didnt it give any conflict?
0
 

Expert Comment

by:mathieu_cupryk
ID: 22909606
how come u did not use cross page postback?
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
In .NET 2.0, Microsoft introduced the Web Site.  This was the default way to create a web Project in Visual Studio 2005.  In Visual Studio 2008, the Web Application has been restored as the default web Project in Visual Studio/.NET 3.x The Web Si…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question