ALLTRIM()

Custom

This base class is the building block for non-visual objects. It's similar to the Container class, except that it can't be seen. Like the other classes that are meant primarily as building blocks (Container and Control), Custom's name is somewhat overloaded. We'll use capital "C" when we mean the class.

Subclass Custom for most classes that don't need to appear on a form (though Timer, ActiveDoc and HyperLink are better when you need their specific abilities). Although Custom-based classes have no visual appearance, you can and should build them in the Class Designer rather than in code.

Custom has only a few PEMs, the ones that are shared by every class like Name, Class, Init and Destroy, and the ones that all containers have, like AddObject and RemoveObject.

If you don't need the container capabilities of this class, but are just using it as a convenient place to hang a few custom methods and properties, consider using some of the other base classes. Several are even simpler and may consume fewer resources than Custom. One area where this is especially true is instantiation time, if you need a slew of them. Contributor Steven Black has suggested Line and Relation as "ultralightweight" classes.

Property

Value

Purpose

Picture

Character

A picture used to represent the class in the Form and Class Designers.


Example

* See SQLConnect() for a class based on Custom

See Also

Container, Control, SQLConnect()


View Updates

Copyright © 2002 by Tamar E. Granor, Ted Roche, Doug Hennig, and Della Martin. All Rights Reserved.



Hacker's Guide to Visual FoxPro 7. 0
Hackers Guide to Visual FoxPro 7.0
ISBN: 1930919220
EAN: 2147483647
Year: 2001
Pages: 899

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net