Variable naming conventions in C# (and VB)

by Pascal Parent 21. June 2007 00:06

Read this article in your language IT | EN | DE | ES

Now here is an argument waiting to happen and, as you may have figured out, I love a good argument ...

My take on variable naming conventions in C# is as follows:

  1. Use of an underscore for any class scoped variables (private) which allows you to use the same name (save for the Underscore) for your properties.
  2. Use Camel Case
  3. Use meaningful descriptive names so that any other developer can understand what it contain.

It makes it easy to read and remember how to code.

Simplify.

But if you really feel this is way too simple, here is a list of resources:

Or simply search Google.

The point is that no one really agrees.

Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Tags: ,

General

Comments

Add comment


(Will show your Gravatar icon)

  Country flag

biuquote
  • Comment
  • Preview
Loading



Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2010 The ASP.NET Guy