Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Optional parameters and how to deal with them
Message
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00790865
Message ID:
00790926
Vues:
29
>Bonnie, does that work in C# too?

even though I'm not Bonnie, I can answer that: Nope, you can't do that in C#. C# is much more strict about it, and when you are trying to call a method, you have to pass all the parameters, otherwise you won't be able to compile the code. If you really want an "optional" parameter, you'll have to overload the method, creating one version with and another version without the parameter.
Claudio Lassala
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform