Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Command button class
Message
 
To
26/04/2000 08:56:12
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00363521
Message ID:
00363539
Views:
19
>I want to create a command button class. I have created 2 properties
>cform and cvalue, so In the click method, I put the coding like this:-
>
>retval=" "
>do form this.cform
>this.cvalue = retval
>
>Therefore, When I use this class in the form, I just put fstock to the cform, and cvalue = thisform.txtstock.value. But It fail for me to call form (fstock) why? coding will be appreciated. Thanks
>I am using vfp 5.00
>
>Sorry for english.

You should use
do form (this.cform)

If the retval is a value which the form should return, it makes sense to make the form that you launch Modal, and use

DO FORM (this.cform) TO this.cvalue

You should return the value in the form.unload() like:
RETURN somevalue
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Previous
Reply
Map
View

Click here to load this message in the networking platform