Not able to retreive value in text box which is read only and is assigned as a control to validate in Required Field Validator

Dear All,

Please help me to find a solution for this, it is a bug when the following condition is there.

I have a text box which is getting some values say [Employee name] from a popup window which is open, after binding the values to the text box, the popup dissappears [javascripts are written for this]. Till here it is okey

Basically the text box is readonly, and it is assigned as a control to validate control with a required field validator contol.

Now

When ever some event [server event] occurs  I am not able to retrieve the value inside the text box. The value in the text box dissappears and the Required Field validator error messge is displayed in the web page.

The following code is what I have written ..

The code is not even working when Validation group is given.  Please Help .................

<asp:TextBox ID="txtsearch" runat="server" ReadOnly="true"></asp:TextBox>

<asp:RequiredFieldValidator ID="reqValidation" runat="server" ControlToValidate="txtsearch">PLEASE SEARCH </asp:RequiredFieldValidator>

0
Joseph
5/16/2008 9:52:23 AM
asp.net.web-forms 93655 articles. 3 followers. Follow

2 Replies
640 Views

Similar Articles

[PageSpeed] 13

I think this is the same as this post.

"Sometimes I think the surest sign that intelligent life exists elsewhere in the universe is that none of it has tried to contact us."
0
ramblor
5/16/2008 11:14:10 AM

hello joseph are  increasing your posts??

any check ur previous post i have given the solution

feel free to ask for any further queries


HAPPY CODING
http://shobhitrai.blogspot.com/
0
shobhit
5/16/2008 12:05:58 PM
Reply:

Similar Artilces:

Not Able to Retrieve Value in A Text box if it is Read only and is assigned as control to validate with Required Field Validator
Dear All, Please help me to find a solution for this, it is a bug when the following condition is there. I have a text box which is getting some values say [Employee name] from a popup window which is open, after binding the values to the text box, the popup dissappears [javascripts are written for this]. Till here it is okey Basically the text box is readonly, and it is assigned as a control to validate control with a required field validator contol. Now When ever some event [server event] occurs  I am not able to retrieve the value inside the text box. The value in the text ...

Required field validator not validating empty text box
I have a textbox in a template field on a details view.  A RequireFieldValidator is attached to the textbox to validate.However, I enter an empty string and no validation occurs.  The following code is below: <EditItemTemplate> <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("jctName") %>' MaxLength="25" ></asp:TextBox> <asp:RequiredFieldValidator ID="rfvCat" runat="server" ControlToValidate="TextBox1" ErrorMessage="*"></asp:RequiredFieldValidator> </EditIt...

Required Field Validation
Am having 2 input controls - dropdownlist (ddl) & textbox for same input. Situation is that user can select the value from ddl or can input the value in textbox. In case users' choice is not present in the ddl user can input the value in textbox. If neither the value is filled in ddl nor in textbox, required field validator should pop up. Looking for solution either using required field validator or some other means. Thanks in advance.    Duplicate thread...Please follow posts here.. http://forums.asp.net/t/1402179.aspxMy Blog"Don't be afraid to be wrong; othe...

Validating multiple text boxes with required validator
I have a form and in it I have many texboxes and label controls. I also have 3 text boxes for 3 email addresses.  A user can enter upto 3 email addresses in these.  So atleast he should enter one email address.  In this case for which text box I should add the required field validator control?  Because the user can simply add an email address either in the first or second or third text box (or he can enter all 3 or only 2). If I add the validator control and the regular expression control only to the first text box, then if the user entered an email address in the secon...

Using custom and required field validator in the same validator control
Hi. I am trying to use a validator which will check that a field has been entered (required field) and that the field is valid. I am cheking that the field is valid with a regex validator. I would like to merge the two validator controls into one validator control. I think the way to do this is to use the custom validator. Can someone please tell me how to use the custom validator? How do I use a regex in a custom validator and incorporate a required field validation in it ? Thanks in advance Well you can to write the client side  function of the custom validator to check for th...

required field validation on web form
hello all, I currently have a web form which allows the users to insert data into a database. I have set up a few required field validators on a some textboxes. When the users hits the submit button, if these textboxes have nothing in them a message will be displayed to the user to fill in the required fields. This works fine. However, I have another button on my webform which when clicked makes a calendar visible. However I cannot click this to display the calendar without filling in the textboxes with the required field validators assigned to them. Does anyone have a work around to ...

Validation controls are triggereing other forms validation controls?
Can someone please look at this an explain whats going on. When you click on subscribe it triggers my registration form validation controls. I'not sure what "subscribe" is supposed to do, but if you dont want it to cause validation, set the CausesValidation property to false.Mike Banavige~~~~~~~~~~~~Need a site code sample in a different language? Try converting it with: http://converter.telerik.com/ Make sure the feild is an email address Hey coolkidsonly, your initial posting didn't show us anything to look at. We are just guessing here without the specifics. However, m...

require field validator on a goup of text boxes
I have six text boxes that need to be validate as a group, that is that at least one text box must have something in it but not all and it does not matter which text box. These six are not the only text boxes on the page. It is that these six are for ticket#s from different tracking system and there must be at least one ticket # in one of the six. Use a customvalidator and just write the javascript to check each one until it finds one with something entered. If it finds nothing in all textboxes, then make the validator trigger.C# / C++ Developer...

Validation
Am facing a problem in Requried Field Validation. Am having 2 input controls - one drop downlist & one textbox for same input. User needs to select from drop down list. In case user's choice is not present in dropdownlist, users' can input their choice in textbox. I need to intimate user to input the field in case user has not selected any value from drop down list or has not input in the textbox. How can i alter the use of required field validator to associate 2 controls with it? Basically am looking for required field validator to be associated (ControlToValidate) with 2 contro...

Required field validator not validating
My validator is attached to a 'Last Name' textbox called tx_lname.  Unfortunately, when I submit my page it is not working, and processing continues instead of throwing an error message as it should.  I had to set the Initial Value of the validator to '-1' in order to correct an earlier problem which can be found in the short post: http://forums.asp.net/t/1283621.aspx However, I wonder if by correcting my first problem I introduced this one. Help is greatly appreciated.  Thank you."Hey, how come pirates are so cool?""They just ARRRGGGHHHH!!!...

Required Field Validator Not Validating...
Hello everyone,I am working on a project for a very simple form. The form is laid out using GridLayout.  I setup Required Field Validators for all of the textboxes in the form.. For some reason, even after I bound the required fieldvalidators to their respective controls, they will not validate the controls.  Is there something missing? It is like the validators aren't enabled, or something.  The code is being executed before the validators do their job.  So, when you hit submit on the form I get input string errors since there was no data in the textboxes.  I always...

how to change permanently the control to validate property programatically on a required field validator
Hello to all you guys i hope you can help me, i have a problem with a requeried field validator, the idea is to change the control to validate property, to a different textbox in the page in order to allow the textbox thats was validated to be free to take empty values and submit them, then if the dropdownlist text changes to another element the control to validate property comes back to validate the prior control, pushing the user the enter a value on it again in order to submit their info. I have tried to set the control to validate property for the...

Can I use MaskedEditExtender and MaskedEditValidator for text validation & required field validation?
Hi, I have just recently learned how to use MaskedEditValidator and MaskedEditExtender for masking & validation. I am wondering if I could use these for regular text validation?  Such as replacing the use of RequiredFieldValidator?  I don't want to use Javascript if not necessary. I like the fact that I can tie css to the MaskedEditExtender and Validator when cursor is moved to the field etc. Thank you!  It --might-- be possible.. from looking at the documentation it seems that you might be able to set MaskType="None" on the maskededextender and then on y...

One required field validator for two text boxes
I have a form with a text box for "Home Phone" and one for "work Phone."  The user needs to enter either their home OR their work number.  How can I have a required field validator check for one or the other? I tried using a label instead of a validator control, with: If (tbHomePhone.Text Is Nothing) Or (tbWorkPhone.Text Is Nothing) Then   lPhoneValid.Visible = TrueEnd If But that didn't work. Any suggestions? When the built in validators don't work, switch to using the CustomValidator (or my Professional Validation And More which can handle this case with ...

Web resources about - Not able to retreive value in text box which is read only and is assigned as a control to validate in Required Field Validator - asp.net.web-forms

CSE HTML Validator for Windows (Official Site) - Powerful HTML Validator, XHTML Validator, CSS Validator ...
CSE HTML Validator is a powerful and easy to use offline HTML, XHTML, CSS, JavaScript, and PHP syntax checker, HTML validator, XHTML validator, ...

DNSSEC/TLSA Validator
DNSSEC/TLSA Validator is a web browser add-on which allows you to check the existence and validity of DNS Security Extensions (DNSSEC) records ...

Feed Validator for Atom and RSS
F E E D Validator for Atom and RSS and KML Jump to navigation RSS Profile Support Added ( more ) Home · About · News · Docs · Terms Copyright ...

iValidCard - Credit Card and Debit Card Number Validator on the App Store on iTunes
Get iValidCard - Credit Card and Debit Card Number Validator on the App Store. See screenshots and ratings, and read customer reviews.

Not fare: new myki card validators lack account balance information
New myki card validators will not tell passengers what their fare is, nor their account balance, leaving unable to monitor their myki use as ...

Mozilla launches new JavaScript-based Add-ons Validator for developers
... that the validation tool provided by Mozilla is unreliable and difficult to use. Today the company announces that the old Python-based validator ...

Business Insider Built An Awesome Analytics Validator And You Can Use It
At a fast-growing media company like Business Insider, keeping accurate analytics is absolutely essential. Editors rely on our analytics dashboard ...

Jon Voight, Validator of Right-Wing Frenzy
Jon Voight was once known for his acting chops and, later, for fathering Angelina Jolie. These days? Well, he's known for his rabid right-wing ...

chriso/validator.js · GitHub
validator.js - String validation and sanitization

Bing Webmaster Tools Adds Markup Validator
The Bing Webmaster Blog announced they have added a new feature to the crawl section named Markup Validator. To access this new feature, login ...

Resources last updated: 11/28/2015 10:38:31 PM