I'm noticing a lot of VB.net examples are not using hungarian notation
(or variants of it) when declaring variables (i.e. strMyString,
iMyBoolean etc).
Is there a generally accepted "norm" for naming variables? What do
you guys use? 6 5744
The trend is definitely away from hungarian notation...MS is discouraging
its use b/c they feel its not longer necessary. I know they have a link to
their suggested guidelies (and if you download fxcop of gotdotnet.com it has
them) but I can't seem to find it...I'll post it if I can. But check out fx
cop in the interim, i'm 99% sure it has all of the guidelines.
HTH,
Bill
"Chuck" <Ch***@c2c.co m> wrote in message
news:2p******** *************** *********@4ax.c om... I'm noticing a lot of VB.net examples are not using hungarian notation (or variants of it) when declaring variables (i.e. strMyString, iMyBoolean etc).
Is there a generally accepted "norm" for naming variables? What do you guys use?
The trend is definitely away from hungarian notation...MS is discouraging
its use b/c they feel its not longer necessary. I know they have a link to
their suggested guidelies (and if you download fxcop of gotdotnet.com it has
them) but I can't seem to find it...I'll post it if I can. But check out fx
cop in the interim, i'm 99% sure it has all of the guidelines.
HTH,
Bill
"Chuck" <Ch***@c2c.co m> wrote in message
news:2p******** *************** *********@4ax.c om... I'm noticing a lot of VB.net examples are not using hungarian notation (or variants of it) when declaring variables (i.e. strMyString, iMyBoolean etc).
Is there a generally accepted "norm" for naming variables? What do you guys use?
Hi Chuck
Have a look here for what Microsoft has to say on the matter: http://msdn.microsoft.com/library/de...Guidelines.asp
HTH
Charles
"Chuck" <Ch***@c2c.co m> wrote in message
news:2p******** *************** *********@4ax.c om... I'm noticing a lot of VB.net examples are not using hungarian notation (or variants of it) when declaring variables (i.e. strMyString, iMyBoolean etc).
Is there a generally accepted "norm" for naming variables? What do you guys use?
Hi Chuck
Have a look here for what Microsoft has to say on the matter: http://msdn.microsoft.com/library/de...Guidelines.asp
HTH
Charles
"Chuck" <Ch***@c2c.co m> wrote in message
news:2p******** *************** *********@4ax.c om... I'm noticing a lot of VB.net examples are not using hungarian notation (or variants of it) when declaring variables (i.e. strMyString, iMyBoolean etc).
Is there a generally accepted "norm" for naming variables? What do you guys use?
* Chuck <Ch***@c2c.co m> scripsit: I'm noticing a lot of VB.net examples are not using hungarian notation (or variants of it) when declaring variables (i.e. strMyString, iMyBoolean etc).
Is there a generally accepted "norm" for naming variables? What do you guys use?
Personally, I stick to the rules, except I do /not/ use camel-case for
variables.
<URL:http://dotnet.mvps.org/dotnet/code/miscsources/>
-> "Bennenungsrich tlinien und Code-Konventionen"
Just ignore the German language text and have a look at the links!
--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
* Chuck <Ch***@c2c.co m> scripsit: I'm noticing a lot of VB.net examples are not using hungarian notation (or variants of it) when declaring variables (i.e. strMyString, iMyBoolean etc).
Is there a generally accepted "norm" for naming variables? What do you guys use?
Personally, I stick to the rules, except I do /not/ use camel-case for
variables.
<URL:http://dotnet.mvps.org/dotnet/code/miscsources/>
-> "Bennenungsrich tlinien und Code-Konventionen"
Just ignore the German language text and have a look at the links!
--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/> This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Phill |
last post by:
Does anyone know the reasoning for Microsoft abandoning Hungarina
Notation in C#?
I have found it very usefull in C++. I like this style:
constant: MY_CONSTANT
methos: myMethod()
class: MyClass
variable: iMyInteger
|
by: Chuck |
last post by:
I'm noticing a lot of VB.net examples are not using hungarian notation
(or variants of it) when declaring variables (i.e. strMyString,
iMyBoolean etc).
Is there a generally accepted "norm" for naming variables? What do
you guys use?
|
by: CMM |
last post by:
So after three years of working in .NET and stubbornly holding on to my old
hungarian notation practices--- I resolved to try to rid myself of the
habit. Man, I gotta say that it is liberating!!! I love it.
At first I struggled with how to name controls. I tried to keep some sort of
notation with them... but I threw that away too!!! I now name them as if
they were simply properties of the form (FirstNameLabel, etc.)... which they
ARE!......
|
by: Ronald S. Cook |
last post by:
An ongoing philosophical argument, I would like your opinions. With the
release of .NET, Microsoft spoke of moving away from the notation as a best
practice. I'm a believer for a few reasons:
1) Consistency throughout and knowing which objects are yours
(clsEmployee, tblEmployee, frmEmployee, etc).
2) Not having to name an employee form EmployeeForm.aspx because the
mane is already taken by your class named Employee.cs
|
by: darrel |
last post by:
I just discovered that MS recommends that we NOT use hungarian notation with
the .net framework:
http://msdn2.microsoft.com/en-us/library/ms229045.aspx
What are the real cons for using it?
I tend to use it a lot, especially when IDing my controls. For instance the
controls in a contact form I create could be IDed as such:
| |
by: Ronald S. Cook |
last post by:
I've been weaning myself off of Hungarian notation because that's what
Microsoft is telling me to do, and I want to be a good little MS developer.
But things keep coming up that make me miss my little 3-character prefixes.
I'm fine with EmployeeFirstNameLabel instead of lblEmployeeFirstName, but at
the table and class level, I get frustrated because terms I want to use
reserved keywords.
I wanted "Event" and "User" as classes and table...
|
by: Ronald S. Cook |
last post by:
For all those anti-Hungarian notation people out there, how would you name
an employee first name label and textbox on an create/modify employee form,
respectively (please)?
Thanks,
Ron
|
by: dom.k.black |
last post by:
I am looking at starting a new piece of work for a company who are
heavily into hungarian notation for C coding.
Any killer arguments for NOT carrying this terrible practice forward
into new C++ code?
|
by: inhahe |
last post by:
Does anybody know of a list for canonical prefixes to use for hungarian
notation in Python? Not that I plan to name all my variables with hungarian
notation, but just for when it's appropriate.
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |