Name
This property is one of the keys to OOP. It's what you use to refer to an object so you can look at its properties, change them, or call a method.
Usage |
oObject.Name = cName cName = oObject.Name |
Despite the warning above, in a code class, don't ever assign Name a value in the properties section unless it's the same as the class name. Instead, assign the new instance a Name in Init. When you do the assignment in the properties section, it changes the name of the class, not the name of instances of the class. |
Example |
DEFINE CLASS MyTextBox AS TextBox * Don't do this! * Name = "anything" * But do this for speed issues, if using a coded class. Name = "MyTextBox" PROCEDURE Init * Do it this way instead, or the class name changes. This.Name = "anything" ENDPROC ENDDEFINE |
See Also |