Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Which c# naming convention?

Reply
Thread Tools

Which c# naming convention?

 
 
Rick
Guest
Posts: n/a
 
      01-19-2004
Hi,

I found these suggestions from Woody Pewitt on the net. Do you agree this is
a best practice?

Rick

BEGIN

- Hungarian notation is out!
- For public interfaces, use PascalCasing
- For private members, use camelCasing
- Use underscore "_" character to denote private class members
- Use camelCasing for all method parameters


public class Customer
{
private string _password;

public void SetPassword(string newPassword)
{
_password = newPassword;
}
}


END


 
Reply With Quote
 
 
 
 
Paul Glavich
Guest
Posts: n/a
 
      01-19-2004
This link on MSDN has a bunch of guidelines, including coding/naming
guidelines from Microsoft.

http://msdn.microsoft.com/library/de...us/cpgenref/ht
ml/cpconnetframeworkdesignguidelines.asp

--
- Paul Glavich


"Rick" <(E-Mail Removed)> wrote in message
news:#(E-Mail Removed)...
> Hi,
>
> I found these suggestions from Woody Pewitt on the net. Do you agree this

is
> a best practice?
>
> Rick
>
> BEGIN
>
> - Hungarian notation is out!
> - For public interfaces, use PascalCasing
> - For private members, use camelCasing
> - Use underscore "_" character to denote private class members
> - Use camelCasing for all method parameters
>
>
> public class Customer
> {
> private string _password;
>
> public void SetPassword(string newPassword)
> {
> _password = newPassword;
> }
> }
>
>
> END
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
while executing my client program i get the exception javax.naming.LinkException: [Root exception is javax.naming.LinkException: [Root exception is javax.naming.NameNotFoundException: remaining if plz anybody know how to solve this problem then mahesh Java 0 03-08-2007 12:26 PM
Javax.naming Exception: name not found in naming service. Harman Java 1 07-28-2006 08:51 AM
Microcontrollers: which one ? which language ? which compiler ? The Jesus of Suburbia NZ Computing 2 02-11-2006 06:53 PM
Network Naming John Williams Wireless Networking 4 10-01-2005 01:18 PM
Naming bookmark folders Petey the Wonder Dog Firefox 0 08-17-2005 09:48 AM



Advertisments