Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP - .NET blog
Message
De
04/05/2009 19:10:10
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
01397536
Message ID:
01397882
Vues:
88
>If you wanted to override the default value (that is, someProperty exists in OldSubclass), you would have to do it in the constructor. Behind the scenes the .NET compiler implements default values via the parameterless constructor (if you don't create one, .NET will automatically it for you). Basically that means the above code gets translated into something like:
>
>
>public class NewSubclass : OldSubclass
>{
>   public string someProperty;
>   public NewSubclass()
>   {
>      this.someProperty = "New Value";
>   }
>}
>
>
>
>re: "My example had zero lines of method code" - I'm not sure why that's a big deal. Yes, it's different than VFP. But is that really a big surprise? .NET isn't VFP and VFP isn't .NET. They're different languages and have different semantics around how things are done.

Just... it's part of the visual studio, and it has to be done in code. VFP is not, ever since VFP7, and it can do this visually since day one. Looks like a paradox to me.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform