Afternoon all.
Here's an easy one for you that I can't figure out.
I have a requiredfield validator that is doing its job too well! Upon the lnkLogOut, the user should be logged out but the requiredfield validator is preventing this.
protected void lnkLogOut_Click(object sender, EventArgs e)
{
Session.Abandon();
...
Hello,
I've got a simple form with some textboxes. These textboxes all have a RequiredFieldValidator. If field 1 is filled in I need to disable the RequiredFieldValidator of field 2 because only one of these fields is required. What is the best way to accomplish this?
...
Using javascript or jquery, how can I make a Required Field Validator control (of ASP.NET) visible. If we check the viewsource of the Required Field valiator, we can see that the visibility is false initially. $("#spanReqFieldValidator").show() / fadeIn() wont work.
Any thoughts ?
From googling, I understand that jQuery has some issue...
Hi guys I use 2 requiredfiledvalidator for 2 selects, one is working but the second one (the one I need) isnt
<asp:dropdownlist id="ddlMod" runat="server" Width="235px" AutoPostBack="True" Font-Names="Arial" Font-Size="XX-Small">
</asp:dropdownlist>
<asp:requiredfieldvalidator id="RequiredFieldValidator1" runat="server" Font-Names="...
My requiredfield control is validating the "SEL"(default invalid value) value but when I do change the value to a valid one, the ErrorMessage/Text does not disappear until I submit the form again.
<asp:DropDownList ID="ddlDocumentType" runat="server" DataTextField="Description" DataValueField="Code" />
<asp:RequiredFieldValidator Contr...
Hi
When i use RequiredFieldValidator for Validation FCKEditor , The first time that the form gonna submit , RequiredFieldValidator prompt (ErrorMessage) and indicate that FCKEditor is empty , while it isn't . Again if you try to submit the form , It's OK and there is no problem .At this case user have to hit the submit button twice ...
I have an ASP.NET form with three text inputs, one each for "Work Phone", "Home Phone" and "Cell Phone". Each of these text inputs has a RequiredFieldValidator associated with it. I also have a DropDownList where the user can select the preferred phone type.
I want to only require the field that is selected in the DropDownList. For exa...
Hi,
I populate two dropdownlist in asp.net.
Both are assigned to a required field validator.
The codebehind is as below
if (!Page.IsPostBack)
{
DataTable dt = new DataTable();
dt.Columns.Add("emp");
dt.Columns.Add("ename");
for (int i = 0; i < 5; i++)
{
...
I've got a drop-down where the user selects a Country. It is a required "field".
Next to it, there is a textfield named State. If the user selects US, then the field State is required. If the user selects e.g. Sweden, the State is not required, since Sweden has no states.
Example code:
<asp:DropDownList runat="server" ID="Country"></a...
I have a WebForms app that uses a field validator on a dropdownlist. It works in IE but not FireFox.
This is pretty straightforward stuff I'm doing. Here are the setups for the dropdown and validator:
<asp:DropDownList ID ="dmbFileActNo" runat="server" CssClass="DROPDOWN_MEDIUM" AutoPostBack="True"></asp:DropDownList>
<asp:require...
Is it possible to have "Required Field Validator" controls to validate more than one field (example I have 12 textboxes that are required. I want to try an avoid having 12 RFV controls. If a validation does get triggered, is there a way to display a customized message ("textA is empty" or "textB is empty") etc.?
...
now, the error message will display if I move out of current textbox. I don't want to display it until I click submit button.
...
I have 2 asp.net textboxes in an update panel. Both textbox controls have some javascript attached to autotab to the next field and to allow only numeric input. When I enter some data into the first field and press enter, focus shifts to the next field and the requiredfieldvalidator of the second field displays its "* required" error mes...
I have a web form with a number of textbox controls which I've associated RequiredFieldValidator's with. I have a ValidationSummary control on the page to render any incomplete fields when I submit the page.
However, I've just had to add an image upload facility to the same page, and have an 'Upload' button which I have posting back to ...
Hi,
We have a model with properties decorated with [Required] which works great for validation. However, what we'd like to do is mark those required fields in the view with an asterisk (or some other style) to denote they are required before the user enters any data for validation.
I don't seem to be able to find anything built into t...
this is part of code for my checkbox.
For Each c As Contact In contacts.Entries
counter += 1
tr = New HtmlTableRow
tc = New HtmlTableCell
Dim chkbox As New CheckBox
chkbox.ID = "id_" & counter
tc.Controls.Add(chkbox)
tr.Cells.Add(tc)
Next
now this ...
is there any mistake in this validation???
var $validate = array(
'brand_id' => array(
'required' => array(true),
'message' => array('select a brand'),
)
);
brand_id is a select box
It show error as "message" instead of "select a brand"
if the message is not in array it shows error
Warning (2): preg_match() [function.p...
I have a aspx page that several of the same usercontrols on the page. The usercontrol houses a textbox that has a Required field validator on it. The validator works but the setonfocus="true" does not seem to be working, further more, the button the aspx page when the validator shows the error message, the button still fires the code b...
I am using RangeValidator to validate date enter in textbox and its working fine with default date format but now i want the date format in "dd/MM/yyy" but its generating excption with this date format. please provide me solution
my code:
in aspx page:
<asp:TextBox ID="txtrequiredby" runat="server" ></asp:TextBox >
<cc1:CalendarExtende...
We deployed our legacy ASP.NET application to production after successful test deployments to our staging environment. The application makes use of RequiredFieldValidators on one particular registration page. On our development and stage environments, the validators successfully detect empty fields when "Submit" is clicked, error messa...