Testing for numerics
Eric Chatonet
eric.chatonet at sosmartsoftware.com
Wed Oct 4 16:09:22 EDT 2006
Re,
I agree.
Actually, I had written a long time ago an universal function, able
to handle any combination of any length.
One argument only: something like the strings I used in the tutorial
as an introduction to specific formats.
But you have to understand well how to specify the format and it
makes things a bit more complicated for anyone :-)
And the stack I have released is a simple tutorial to get any user
started...
So I did no include it ;-)
Le 4 oct. 06 à 21:55, Francis Nugent Dixon a écrit :
> Hi Eric,
>
> I totally agree ! Pre 1980 Data Processing (that was what
> it was called in those days) spent eons vetting, rejecting
> and .... finally ..... integrating external data.
>
> Things changed later, when the idea of checking Data Entry
> "at the source" was born ! Of course, this was only possible
> after the introduction of independant (non-centralized) systems.
>
> I think we all agree that you should not let "sh....t" enter the
> system, then you won't have to spend time fleecing it out.
>
> So ..... Can we now have the "all singing - all dancing" data
> entry routine, with a call sequence like :
>
> put dataentry(x,y) into myreceptionfield
>
> where x is the type of check required, and y is the length to be
> accepted ...... ?
>
> ........ unless, of course, you can think of more criteria .....
>
> This routine could be integrated into your nice "Managing Entry
> Boxes" stack.
>
> However, the equally elegant solution from our unknown
> "FlexibleLearning at aol.com" user is also interesting :
>
>> function isPositiveInteger pValue
>> return (pValue is a number) AND (pValue >=0) AND (trunc(pValue)
>> =pValue)
>> end isPositiveInteger
Best Regards from Paris,
Eric Chatonet
------------------------------------------------------------------------
----------------------
http://www.sosmartsoftware.com/ eric.chatonet at sosmartsoftware.com/
More information about the use-livecode
mailing list