>if i execute this line of code:
>
>FldGetTextPtr(FrmGetObjectPtr(frm, FrmGetObjectIndex(frm, objectID)));
>
>i get the text of a field in my form.  i then convert it to an integer
>using StrAToI().  now if i do this on an empty field, the resulting Long
>turns out to be 0 (zero).  i want to try to catch an empty field for an
>error.  what does an empty field return?  i have tried 0 (zero), NULL,
>and "" (empty string), but it seems to be none of these.  anyone know
>what i should test for?

Try FldGetTextLength() and check for a result of 0. FldGetTextPtr() 
returns different results depending upon whether the field is just 
currently empty or has always been empty (never assigned text).

JB


----------------------------------------------------------------------
JB Parrett                         603-673-5046
True North, Inc.                   603-673-5035 FAX
9 Pulpit Run                       [EMAIL PROTECTED]
Amherst, NH 03031-1510             http://northisup.com

It is interesting to note that there are only two enterprises in the
world that refer to their patrons as 'users.' - Edward Tufte
----------------------------------------------------------------------

Reply via email to