Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Assign method problem
Message
General information
Forum:
Visual FoxPro
Category:
Object Oriented Programming
Miscellaneous
Thread ID:
00381071
Message ID:
00381689
Views:
28
Roi,

Yes, you can use asserts exactly like that. In my case it's not really as much a "design time" error as it is a safety valve.

>Right, I thought asserts in that case would be better. In your expample you could just:
>
>ASSERT RIGHT(This.MyValue, 1) == '\' ;
> MESSAGE 'Property MyValue must contain the trailing backslash'
>
>In the class init. Now it runs when you are developing and you can turn it off when you compile the finished app.
>
>Or am I misunderstanding how asserts are used?
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform