on 09-13-2006 3:04 PM
Hi all,
I want to check an input field, if the user enter a numeric value, e.g. "A001" is wrong and the user gets an error. I tried it about the validation function, but I think there is no chance to use something like [a-z] as in java script.
Has anybody an idea?
Regards,
Marcel
can you use validation condition edit
select Form view Components
select Field -> Control
pop up Control Properties
select tab Validation
Condition -> select Test
value -> double click !! -> Validation Condition
type this or your formula
!(CHR(LEFT(@STR1,1))>64&&CHR(LEFT(@STR1,1))<91)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Marcel,
Did you try to use the Validation function on the input field.
There are many options like
Contains
Not Contains
Is equal
Is Blank
Begin with etc. For example u needs to say contains a,b etc then throw error message.
I hope this will work for you in this case.
Regards
Ajay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thx for the answer. But I know the options.
I would like to know if it's possible with a certain parameter like in JavaScript [a-z] or something like that, that an error message occurs for each lette between a to z with only one validation instead of 26 valdidations like:
Contains 'a' "Error message"
Contains 'b' "Error message"
Contains 'c' "Error message"
and so on.
26 times for a-z
26 times for A-Z
You understand what I mean?
Regards,
Marcel
Hi Marcel
I did this kind of validation
try this
Ask if the character is not in the ASCII number range
for the first character
!( (ASC(at(@str1,0))<48 && ASC(at(@str1,0))>57) )
You could do this for 4 digits, like this
!( (ASC(at(@str1,0))<48 && ASC(at(@str1,0))>57) && (ASC(at(@str1,1))<48 && ASC(at(@str1,1))>57) && (ASC(at(@str1,2))<48 && ASC(at(@str1,2))>57) && (ASC(at(@str1,3))<48 && ASC(at(@str1,3))>57) )
Best Regards from Peru¡
User | Count |
---|---|
76 | |
9 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.