Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Execute the parent class method, but not a grandparent
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00535248
Message ID:
00535281
Vues:
15
>Nadya,
>
>This is a pretty classic example of a bad thing. There's either a problem with the grandparentclass or the parentclass design. It's more appropriate to fix that problem than workaround it. If you call the parentclass and it has a dodefault() the grandparentclass code will execute.
>
>If you now need conditional behavior use a property setting that your subclass can change.
>

David,

I agree. I even knew, I will get this answer :) I already sent a message to our team members, what I want to remove grandparent class code or at least make it conditional. Unfortunately, the person, who is responsible for our classes updates, is on vacation. I also know, that each of my requests, related with classes, usually is neglected. I don't see any other possibilities than changing the grandparent class here :(



>>In a grid AfterRowColChange I have some custom code, when I invoke
>>its parent code with dodefault(nColIndex). This grid is based on Highlighted grid, so this code does highlighting. I've just checked our wggrid class and found out, that it has this code:
>>
>>LPARAMETERS nColIndex
>>*--------------------------------------------------------------------------
>>* -- NSL 2/29/00 Per request of Nadya
>>* -- Added the check for the existance of the hasnavstand property first
>>* -- Nadya must be using this grid on a non-WG form.
>>*--------------------------------------------------------------------------
>>IF pemstatus(thisform,'hasnavstand',5) and thisform.hasnavstand
>>	thisform.navstand.navupdate()
>>ENDIF
>>
>>I don't want to execute this code. How can I achieve it?
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform