Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Empty()
Message
 
 
To
07/10/2004 16:36:14
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00949698
Message ID:
00949761
Views:
11
Paul,

Would this work for you?
	DO CASE 
	CASE EMPTY(Level1) 
		* Error: Level1 cannot be empty
	CASE EMPTY(Level2) AND NOT EMPTY(Level3)
		* Error: Level3 cannot be empty if Level2 is empty
	ENDCASE	
>
>Sorry,Ask the wrong question but to check if
>"field3 integrity failed " when field2 is EMPTY and field3 is still fill WITH some characters
>
>You can use EMPTY() function.
>
>How to check if field1 is never empty, field2 is empty sometimes that field3 must be empty too ?
>
>mytable.dbf
>
>field1 field2 field3
>
>aaaaaa bbbbbb cccccc
>dddddd
>eeeeee ffffff ggggggg
>
>a second row with dddddd in field1 should have field2 and field3 empty.
>
>if field3 is not empty
>
>dddddd BLANK kkkkkk(field3)
>
>this row should provide some error message ?
>
>
>use mytable
>
>SCAN
>*    - "Level 3 integrity failed [class code]" when level 2 is EMPTY and level 3 is fill WITH 123
>
>   IF EMPTY(level2) and EMPTY(LEVEL3)
>
>   ANS = MESSAGEBOX(''+CLASSCODE+''+LEVEL1+LEVEL2+LEVEL3, 0, 'LEVEL2 EMPTY BUT LEVEL3 FILL')
>
>   ENDIF
>*!*	LOCAL lcAns
>
>*!*	    lcAns= IIF(EMPTY(level2),EMPTY(level3),.T.)
>*!*	
>*!*	    ?lcAns
>
>
>ENDSCAN
>
>
>
>
>TIA
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform