I think someone else ran into this (maybe Mika?) but I don't remember if it had a work around. This is something we're fixing in 2.0, I don't have a solution for you off the top of my head.
Matt -----Original Message----- From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Kai König Sent: Wednesday, August 17, 2005 6:56 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Changing the wrongLengthError in a DateValidator Hi all, another validator-related question: Having to validate for a date using a DateValidator, the requirements are to just deliver one validation message if the validation fails. Following the concept, I'd have to add a long list of attributes to my validator call, as in: <mx:DateValidator ... invalidCharError="blabla" invalidFormatCharsError="blabla" ... /> So we thought it might be nice to subclass the DataValidator and to define a defaultErrorMessage which we can pass into our own validator class and internally, the class is responsible to overwrite the values of the pre-defined errors. Works quite good, BUT doesn't work for wrongLengthError. The docs state: >Error message when the length of the date doesn't match that of the >inputFormat. Default is "Please type the date in the format ><i>inputFormat</i>.". That means the default error might be something like: "Please...format mm/dd/yyyy" As far as I understand, I'd expect to be able to overwrite the default with anything I like, but regardless to what I set the value for wrongLengthError, Flex always adds the value of inputFormat to my error message - I end up with something like "This is my errortext and I want you to type it correct mm/dd/yyyy" This is especially annoying with localized error messages in which the inputFormat has to be at another place within the error message by grammar: "Bitte nutzen Sie das Format dd.mm.yyyy in diesem Feld". Is there a way to get rid of the automatic concatenation of the inputFormat within the wrongLengthError of this validator? Cheers Kai -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links ------------------------ Yahoo! Groups Sponsor --------------------~--> <font face=arial size=-1><a href="http://us.ard.yahoo.com/SIG=12hl7nb6d/M=362335.6886445.7839731.1510227/D=groups/S=1705007207:TM/Y=YAHOO/EXP=1124354400/A=2894361/R=0/SIG=13jmebhbo/*http://www.networkforgood.org/topics/education/digitaldivide/?source=YAHOO&cmpgn=GRP&RTP=http://groups.yahoo.com/">In low income neighborhoods, 84% do not own computers. At Network for Good, help bridge the Digital Divide!</a>.</font> --------------------------------------------------------------------~-> -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/