473,471 Members | 1,814 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Error in Required Field Validator

16 New Member
hi,
I have taken two file upload control (fileUpload1 and fileUpload2) and two required field validator(requiredFieldValidator1 and requiredFieldValidator2) for the two upload controls mentioned above.i.e requiredFieldValidator1 for fileUpload1 and requiredFieldValidator2 for fileUpload2.Now there are two button btnUpload1 and btnUpload2 for two controls.i.e btnUpload1 is for uploading file of name given to fileUpload1 control and btnUpload2 is for uploading file of the name given to fileUpload2.Now what is happening is that when i gave valid file name in fileUpload1 and clicked btnUpload1, it also checks for fileUpload2 and depending on its container, it is throwing exceptions.Like if fileUpload2 has file name given, no error but when there is no file name given in fileUpload2, it is giving error.However, the requiredFieldValidator1 shouldn't check for fileUpload2.The control to validate for requiredFieldValidator1 is fileUpload1 and for requiredFieldValidator2 is fileUpload2. And the same error comes when i try to upload the file of fileUpload2 and click btnUpload2.Why this error is coming ...How to solve this ...Well i am using ASP DOT NET 2005 using C# .
Oct 2 '07 #1
6 1538
Frinavale
9,735 Recognized Expert Moderator Expert
Hi SayamiSuchi,

What is the exception error that you are getting?
Oct 2 '07 #2
SayamiSuchi
16 New Member
Hi SayamiSuchi,

What is the exception error that you are getting?


hi,
Actually i am not getting any exception error....
Oct 3 '07 #3
Shashi Sadasivan
1,435 Recognized Expert Top Contributor
hi,
Actually i am not getting any exception error....
so programatically, the 2 validators are not validating something else either?

try changing the message for the validators and fish out which message is being shown where.

cheers
Oct 3 '07 #4
SayamiSuchi
16 New Member
so programatically, the 2 validators are not validating something else either?

try changing the message for the validators and fish out which message is being shown where.

cheers

Hello Shashi,
Thanx for your suggestions...I tried it out but though i change the messages for the validators , it is not working...What has happened is that the corresponding message is shown but the previous problem is stable as before...no change....Any idea what to do ??? Hope to hear from you soon .....


Regards,
suchita
Oct 4 '07 #5
Shashi Sadasivan
1,435 Recognized Expert Top Contributor
Could you provide some code that you have done, and the current behaviour....and if posssible the required behaviour too.

cheers
Oct 4 '07 #6
SayamiSuchi
16 New Member
Could you provide some code that you have done, and the current behaviour....and if posssible the required behaviour too.

cheers

Thanx anyway, i solved it putting the Validation group name in both the required field validator and button ....Thanx you for trying to helping me....Thanx anyway....
Oct 5 '07 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Martin | last post by:
Dear Group It says in MSDN that a field can be associated with more than one validators but can one validator be associated with more than one field? Or do I need a validator for each field? How...
2
by: z. f. | last post by:
Hi, i have a field with required field validator. on the client side it's working. when i submit without the required field the page gets back because of not valid, but the message from the...
1
by: Brian Shannon | last post by:
I built a composit control consisting of a calandar control and a text box and an image of a calandar. Depending on what page I place this control the Date field needs to be required. If the...
2
by: Helen | last post by:
I'm having trouble changing the text colour of the validators I'm using on a webform. I want the styling to be done using a CSS class that is attached to the table cell that my validators live...
5
by: Helen | last post by:
Hi I'm using ASP.NET's standard validators to display error messages when people don't fill in required fields on my form. The error messages currently show as soon as the form is loaded, but...
1
by: Sam Collett | last post by:
Is there a way of having a required field validator check to see if at least one of a set of controls has information in it? I'm sure this can somehow be done using a custom validator, but would...
3
by: Skeptical | last post by:
Hello, I have a form and two buttons on it. Button1 submits the data to a database and RequiredFieldValidator is used to make sure all the required fields are filled up, the second button has a...
0
by: nimeshdotnet | last post by:
Hi All, I have a textbox whose readonly property is set to true. This textbox is also guarded by a required field validator. What i m doing that I have a calendar control whose on date selection i...
2
by: sasierkha | last post by:
I have two options yes and no in option button when the user select the option yes it has two textbox with required field validator if value is entered no pbm otherwise error message will be...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.