[DUG] Variables stored

Colin Johnsun colin.adug at gmail.com
Fri Jan 21 21:49:22 NZDT 2011


>
> Actually is Self.Create safe - rather than TMyDialog.Create?
>
I think Jolyon explained it better than me but for me, it means that
there is less code that needs to be modified/maintained.

Self in the class method will refer the class that the method is being
called from.

In the case that I have group of dialog boxes with the same standard
behaviour, I can define a class method Execute in the base class and
use the Self identifier without having to define the Execute class
method in each and every descendant class.

Cheers,
Colin


More information about the Delphi mailing list