General information
Category:
Forms & Form designer
Hi Angela.
>> I try to use the command "line". After I create the form using Create Form command. Then I try to issue "myform.line(1,2,3,4). It still said "Can't find an object" <<
In the form designer, add a new property to your form to hold the paramters passed to it. To do this, click on Form and then new property. Suppose you call this new property cSomeProperty.
You need this property to hold the passed parameter if you want it to be visible to the entire form. Parameters are passed to the form's init and in VFP, variables are scoped to the current method.
In the init of your form, put the line
LPARAMETERS tcSomeVariable
Thisform.cSomeProperty = tcSomeVariable
You refer to the saved parameter in code as Thisform.cSomeProperty.
To do the form from the command window you type
=
DO FORM Myform WITH
HTH
Marcia
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only