1. Newbee question (Stupid??!)

Maybe I am being stupid! But I am new at Euphoria and stuck with the
following:
I am using WIN32 LIB to receive a numeric field using gettext(). gettext()
is returning me a sequence, is there a way I can convert this sequence to
numeric, for validating if the user has at all entered numeric.

Regards,
Prasanta.

new topic     » topic index » view message » categorize

2. Re: Newbee question (Stupid??!)

> Maybe I am being stupid! But I am new at Euphoria and stuck with the
> following:
> I am using WIN32 LIB to receive a numeric field using gettext(). gettext()
> is returning me a sequence, is there a way I can convert this sequence to
> numeric, for validating if the user has at all entered numeric.

You can use value () from get.e
It will return a sequence of two elements like { status, value }

WHen the status equals zero it has succesfully converted the value.
For more information, search for value () in library.doc (library.html)

Good luck.
Ralf N.

nieuwen at xs4all.nl

new topic     » goto parent     » topic index » view message » categorize

3. Re: Newbee question (Stupid??!)

Hi, Prasanta

Try a=getNumber(s) where s is the name of the control on which you are doing
the getText and a is an atom. If your control contains sequences
instead of numbers, be aware that getNumber will return zero. Basically
getNumber() does getText and value(). You can find value in the EU docs and
getNumber in the WinLib HTML doc.

Regards,
Judith


> is there a way I can convert this sequence to
>numeric, for validating if the user has at all entered numeric.
>
>Regards,
>Prasanta.

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu