views:

372

answers:

8

What is a widely accepted naming convention for .NET/C#/WPF projects?

+7  A: 

Microsoft has an extensive MSDN article on naming conventions here.

Igor Zevaka
+1. This is the conventions suggested by Microsoft which is implemented in the .NET class library.
SiLent SoNG
+1  A: 

Instead of listing potentially flammable conventions, I will just tell you that I follow whatever conventions FXCop suggests, with a couple of exceptions.

Padu Merloti
+1  A: 

your best bet would be to

(a) look at a number of FOSS .net projects (b) read Framework Design Guidelines

Preet Sangha
+1  A: 

This is the best article I'm aware of on the subject:

http://groups.google.com.au/group/wpf-disciples/web/wpf-and-xaml-coding-guidelines

DanM
+2  A: 

You can see Philips Healthcare - C# Coding Standard for C#

It look very good.

And of course Design Guidelines for Developing Class Libraries

Incognito
+2  A: 

Use the tools Microsoft FxCop and Microsoft StyleCop for validation.

Steven
+1  A: 

I am trying to follow (Fxcop) recommendation that field names start with small letter and properties with big letter. But, what about WPF control names (those marked with x:Name="theButton"), are they fields or properties?

Arto Viitanen