FM10 adv on Win XP here. I have a field for telephone number and I
would like to validate using the Filter function so that anything else
than
numbers would be filtered out:
Filter (phonenum; "0123456789") // where phonenum is a text type
All right, it looks short and simple, and indeed it works when I
script it but for a reason that I cannot explain,
when I put the same formula through valudation by calculation...it
does not do anything, I am free to write numbers, letters, or symbols
(- @...) with no validation at all.
I know I could run the validation using a script trigger but I would
prefer fix the issue with old plain filemaker (I am working in a
mixed environment and not everyone got FM 10), might you please help
in this ?
Thank you in advance !
Diego
> Hello everyone,
>
> FM10 adv on Win XP here. I have a field for telephone number and I
> would like to validate using the Filter function so that anything else
> than
> numbers would be filtered out:
>
> Filter (phonenum; "0123456789") // where phonenum is a text type
>
> All right, it looks short and simple, and indeed it works when I
> script it but for a reason that I cannot explain,
> when I put the same formula through valudation by calculation...it
> does not do anything, I am free to write numbers, letters, or symbols
> (- @...) with no validation at all.
FWIW, this validation works on my FMP 8 Adv on OS X.4. Two thoughts,
though:
a) the Filter function reportedly may have problems if the your start
the second parameters with a zero. Try "1234567890".
b) You are free to enter anything; FMP will not validate your input
until you commit the record.
--
http://clk.ch
> FWIW, this validation works on my FMP 8 Adv on OS X.4. Two thoughts,
> though:
>
> a) the Filter function reportedly may have problems if the your start
> the second parameters with a zero. Try "1234567890".
Ok, fixed !
>
> b) You are free to enter anything; FMP will not validate your input
> until you commit the record.
Good point, I created a small script to commit/revert the record but
validation still does not seem to work.
When I add the step to validate (script validation then) to the same
script, everything works as expected...a little bit puzzled here
Again, thank you !
Diego