Foxpro form control "object not found" (but it existed in the form!)

1.5k views Asked by At

I am trying to make a simple Form in Foxpro, I create the Form name form1, drag two CommandButton Command1 and Command2, In the Click event of Command1:

Command2.Visible = false

When I click, the Error message is: Object "Command2 cannot be found"

I worked in .Net so this is so strange

1

There are 1 answers

0
Alan B On BEST ANSWER
This.Parent.Command2.Visible = .f.

or

Thisform.Command2.Visible = .f.