>Hi All,
>
>I and a friend are having a discussion on how to best create and maintain classes. He suggested that we programmatically code our classes. I, however, am very comfortable designing/coding classes visually - that is, using the Visual Class Designer.
>
>Although one can very well convert a VCX based class (or a Form even) to a PRG class via Class Browser/View Code, the issue of performance and best practices comes to mind.
>
>Which executes faster? Is coding classes programatically more popular? Or better practice?
>
>Many thanks to anyone who shares his/her insights!
>
>Dennis
These are the 3 essential points:
- in a PRG you cannot define a class with members of level two,
ADD OBJECT ParentName1.ParentName2.objectName AS className
ADD OBJECT objectName AS className In ParentName1.ParentName2
and therefore for every member container
you have to redefine an intermediary class
you will add with ADD OBJECT;
this creates an enormous number of combinations
of template classes that will be loaded in memory, occupying a sea of memory.
- The Class Designer doesn't support the classes in the PRGs,
and therefore to define classes in the PRGs is an agony.
- Is possible to create a procedure independent from the datasessions
only as procedure of a PRG,
it is not possible to create a method in an object that is datasession float,
every object has one specific datasession
and therefore every time that calls it you can have a change of datasession,
and this can bring to decelerations or not desired side effects.