Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
DoDefault and inheritance
Message
From
21/02/2008 07:28:51
 
 
To
21/02/2008 05:38:09
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01294645
Message ID:
01294667
Views:
14
I have a class A whose "Init" method reads
Line 1
Line 2
.
.
.
Line 10 <-- (my subclass need a diff code for this line)
.
.
.
DODEFAULT()


This tells me that the parent class is trying to do too much in its Init(). Methods should only do one thing. You also need a hook so your child class can do whatever it needs to do. You can call the hook method from the appropriaye place in the parent class:
Line 1
Line 2
.
.
.
Thisform.MyHookMethod() && Specialized code in the hook method
.
.
.
Previous
Reply
Map
View

Click here to load this message in the networking platform