General information
Category:
Forms & Form designer
Hi Mike,
>Simple question, but giving me a hard time. How do I disable or enable a command button using the THIS or THISFORM command.
It depends where you are calling this, if it is a method of the button you want to disable, you can do:
This.Enabled = .F.
If not, you can use the form in the path:
Thisform.Command1.Enabled = .F.
You will have to designate by name any contianers the button is on that is not the form between "Thisform" and "Command1". There is a third "relative" path keyword you can use too: Parent. It is usually used with This:
This.Parent.Command1.Enabled = .F.
Is this what you wnat?
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