Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Grid-textbox control CAN NOT detect empty value
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00069437
Message ID:
00069947
Views:
32
Andi, sometimes code fails because of extra characters, and sometimes for other reasons. I usually try to set a local variable to 'this.value' and then use that variable.

Also, check with the debugger to see if 'this.value' is truly empty. Is it NULL? 0? What type is it? This could solve the problem, because the value was set to something other than totally blank before you entered the textbox.

Sorry I can't be more explicit.

Barbara


>I use exactly the same code as you showed me. Here is my valid method :
>
> IF EMPTY( this.value)
> RETURN 0
> ENDIF
> IF NOT EMPTY( this.value)
> SELECT othertable
> SET ORDER TO key1
> IF NOT SEEK( this.value)
> MESSAGEBOX(' Item NOT FOUND !',48,'')
> RETURN 0
> ENDIF
> ENDIF
>
>But VFP 5.0 seems to ignore the "IF EMPTY(this.value)" but VFP 5.0 still responds to the "IF NOT EMPTY( this.value)".
>
>Finally, I copy the grid to another temporary form and then I put a new grid on the current form's pageframe (still on page2) and copy all methods from the old grid which is on the temporary form and set the grid's appearance to look the same as the old one and it works. But I still do not know the reason why my old grid does not work.
>
>Could you please tell me why ?
>
>Thanks,
>
>
>
>>>I have a grid on page 2 of a pageframe. The grid has 12 columns.
>>>The problem is that the textbox control in column3 can not detect EMPTY value, why ?
>>>The valid method can only detect NOT EMPTY value and the other methods, too.
>>>
>>>Thanks a lot for your kind help,
>>>Best regards,
>>>Andi Hidajat
>>>pkshq@cbn.net.id
>>
>>Andi, could you give us the code in the valid method? You SHOULD be able to use code like:
>>
>>If empty(this.value)
>> ** your code here
>>Endif
>>
>>Barbara
Barbara Paltiel, Paltiel Inc.
Previous
Reply
Map
View

Click here to load this message in the networking platform