validation controls
-
hello i have used required field and regular expression validator on my page. but either field is empty or not page get post back. plz help me some one
Rajeev Kr. Sharma InfoFace Technologies Pvt. Ltd.
-
hello i have used required field and regular expression validator on my page. but either field is empty or not page get post back. plz help me some one
Rajeev Kr. Sharma InfoFace Technologies Pvt. Ltd.
-
hello i have used required field and regular expression validator on my page. but either field is empty or not page get post back. plz help me some one
Rajeev Kr. Sharma InfoFace Technologies Pvt. Ltd.
-
actualy validation controls shows error message but page get postback. so how to avoid page post back when validation controls show error.
Rajeev Kr. Sharma InfoFace Technologies Pvt. Ltd.
-
i think behaviour of required validation control is to prevent page postback if field is empty.
Rajeev Kr. Sharma InfoFace Technologies Pvt. Ltd.
-
i think behaviour of required validation control is to prevent page postback if field is empty.
Rajeev Kr. Sharma InfoFace Technologies Pvt. Ltd.
yeah this is true, but what's happening with your Requiredfield validator.
Amit Agarwal
-
yeah this is true, but what's happening with your Requiredfield validator.
Amit Agarwal
validation control shows error but page is getting postback on button click.
Rajeev Kr. Sharma InfoFace Technologies Pvt. Ltd.
-
validation control shows error but page is getting postback on button click.
Rajeev Kr. Sharma InfoFace Technologies Pvt. Ltd.
-
can you paste your code (HTML) for the Required Field Validator?
Success is the good fortune that comes from aspiration, desperation, perspiration and inspiration.
<%@ Page Language="C#" EnableEventValidation="false" MasterPageFile="~/Backend/Home.master" AutoEventWireup="true" CodeFile="Backend.aspx.cs" Inherits="Backend_Backend" Title="Untitled Page" %> <%@ Register Assembly="System.Web.Extensions" Namespace="System.Web.UI" TagPrefix="cc" %> <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server"> <script language="javascript" type="text/javascript"> function CheckTime(s,e) { var ddl1 = document.getElementById('<%=ddl_starttime.ClientID %>'); var ddl2 = document.getElementById('<%=ddl_endtime.ClientID %>'); var selIndex1,selIndex2; selIndex1 = ddl1.selectedIndex; selIndex2 = ddl2.selectedIndex; if(selIndex1 > selIndex2) { e.IsValid = false; } } </script> <div class="container"> <div class="containerin"> <div class="head-a"> <div class="head-txt"><a href="#">Manange My Openhomes</a> > <a href="#">Add a New Openhome</a></div> </div> <div><img alt="" src="images/spacer.gif" height="10px" border="0" /></div> <div class="online">Add a new Openhome</div> <div class="bot-table"> <div class="row"> <div>Property Location</div> <div><img alt="" src="images/spacer.gif" height="10px" border="0" /></div> <div align="center"><table width="60%" cellspacing="7" cellpadding="0" border="0"> <tr> <td class="row_form" width="10%" valign="top">Street Number</td> <td align="left" width="50%" valign="top"> <asp:TextBox ID="txtStreetNumber" runat="server" Width="300px" Font-Names="Tahoma" Font-Size="16px" ForeColor="#919295" BorderStyle="Solid" BorderColor="#aaaaaa"></asp:TextBox> <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txtStreetNumber" ErrorMessage="Wrong value street Number not entered" ValidationExpression="^\d+$" SetFocusOnError="True" Display="None"></asp:RegularExpressionValidator> <asp:RequiredFieldValidator ID="rfv_streetno" runat="server" ControlToValidate="txtStreetNumber" ErrorMessage="Street Number not entered" SetFocusOnError="True" Display="None"></asp:RequiredFieldValidator> <asp:ValidationSummary ID="ValidationSummary1" runat="server" HeaderText="Please check the f
-
<%@ Page Language="C#" EnableEventValidation="false" MasterPageFile="~/Backend/Home.master" AutoEventWireup="true" CodeFile="Backend.aspx.cs" Inherits="Backend_Backend" Title="Untitled Page" %> <%@ Register Assembly="System.Web.Extensions" Namespace="System.Web.UI" TagPrefix="cc" %> <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server"> <script language="javascript" type="text/javascript"> function CheckTime(s,e) { var ddl1 = document.getElementById('<%=ddl_starttime.ClientID %>'); var ddl2 = document.getElementById('<%=ddl_endtime.ClientID %>'); var selIndex1,selIndex2; selIndex1 = ddl1.selectedIndex; selIndex2 = ddl2.selectedIndex; if(selIndex1 > selIndex2) { e.IsValid = false; } } </script> <div class="container"> <div class="containerin"> <div class="head-a"> <div class="head-txt"><a href="#">Manange My Openhomes</a> > <a href="#">Add a New Openhome</a></div> </div> <div><img alt="" src="images/spacer.gif" height="10px" border="0" /></div> <div class="online">Add a new Openhome</div> <div class="bot-table"> <div class="row"> <div>Property Location</div> <div><img alt="" src="images/spacer.gif" height="10px" border="0" /></div> <div align="center"><table width="60%" cellspacing="7" cellpadding="0" border="0"> <tr> <td class="row_form" width="10%" valign="top">Street Number</td> <td align="left" width="50%" valign="top"> <asp:TextBox ID="txtStreetNumber" runat="server" Width="300px" Font-Names="Tahoma" Font-Size="16px" ForeColor="#919295" BorderStyle="Solid" BorderColor="#aaaaaa"></asp:TextBox> <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txtStreetNumber" ErrorMessage="Wrong value street Number not entered" ValidationExpression="^\d+$" SetFocusOnError="True" Display="None"></asp:RegularExpressionValidator> <asp:RequiredFieldValidator ID="rfv_streetno" runat="server" ControlToValidate="txtStreetNumber" ErrorMessage="Street Number not entered" SetFocusOnError="True" Display="None"></asp:RequiredFieldValidator> <asp:ValidationSummary ID="ValidationSummary1" runat="server" HeaderText="Please check the f
RajeevKumarSharma wrote:
Hi Why dont you use the Update pannel
If You win You need not Explain............ But If You Loose You Should not be there to Explain......
%>]]>