Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Studio
  4. is it possible to change the Naming convention?

is it possible to change the Naming convention?

Scheduled Pinned Locked Moved Visual Studio
questioncsharpvisual-studioalgorithms
9 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Q Offline
    Q Offline
    QzRz
    wrote on last edited by
    #1

    Hello I have just started as an IT student and ive got the visual studio from the school. There is alot of different ways to name your attributes and objects, however there is a few conventions. After searching the internet I found a few of them very good. If I create a new textbox in visual studio it will call it textBox1 due to one convention 'installed' in the program. Is there a way to change that 'texBox' to another, Fx our teachers tells us that the Hunarian style is really good. So is there a way to change 'textBox' to 'tbx' as the Hungarian style will be. Hopefully it will be done so when I add a new textbox it will be called tbx1 and a button will be called btn1. I hope my question i clear enough regards Qzrz

    O P 2 Replies Last reply
    0
    • Q QzRz

      Hello I have just started as an IT student and ive got the visual studio from the school. There is alot of different ways to name your attributes and objects, however there is a few conventions. After searching the internet I found a few of them very good. If I create a new textbox in visual studio it will call it textBox1 due to one convention 'installed' in the program. Is there a way to change that 'texBox' to another, Fx our teachers tells us that the Hunarian style is really good. So is there a way to change 'textBox' to 'tbx' as the Hungarian style will be. Hopefully it will be done so when I add a new textbox it will be called tbx1 and a button will be called btn1. I hope my question i clear enough regards Qzrz

      O Offline
      O Offline
      originSH
      wrote on last edited by
      #2

      "tbx1" is still not a good name :P You'll need to change it to something meaningful anyway like "tbxCancel" or "tbxBrowse" so changing the default naming scheme wouldn't be all that useful. I think that the names are gotten from the name of the class you are adding rather than some schema and so it wouldn't be possible to change it. Thats only a guess though :)

      Q 1 Reply Last reply
      0
      • O originSH

        "tbx1" is still not a good name :P You'll need to change it to something meaningful anyway like "tbxCancel" or "tbxBrowse" so changing the default naming scheme wouldn't be all that useful. I think that the names are gotten from the name of the class you are adding rather than some schema and so it wouldn't be possible to change it. Thats only a guess though :)

        Q Offline
        Q Offline
        QzRz
        wrote on last edited by
        #3

        I will ofcause need to rename them to something else as you write. But if visual studio would write "tbx1" so I only would have to remane it to "tbxCancel" it would be really good. My guess is that in a few months it wont be neccesary for me as I can remember all the names of the objects you will use most. But in the beginning I think it could be really helpfull so I dont have to look it up on a paper / book / webpage each time I add a new item which I cant remember the name of, or I will get a bad habit of spelling some of the objects wrong. But thanks for the quick answer, I hope someone else can conform that it cannot be changed, as yours only were a guess. //QzRz

        1 Reply Last reply
        0
        • Q QzRz

          Hello I have just started as an IT student and ive got the visual studio from the school. There is alot of different ways to name your attributes and objects, however there is a few conventions. After searching the internet I found a few of them very good. If I create a new textbox in visual studio it will call it textBox1 due to one convention 'installed' in the program. Is there a way to change that 'texBox' to another, Fx our teachers tells us that the Hunarian style is really good. So is there a way to change 'textBox' to 'tbx' as the Hungarian style will be. Hopefully it will be done so when I add a new textbox it will be called tbx1 and a button will be called btn1. I hope my question i clear enough regards Qzrz

          P Offline
          P Offline
          Pete OHanlon
          wrote on last edited by
          #4

          Hungarian notation? Good? Ooohhh boy. That's a contentious statement, and I assume that the teacher has been out of professional development for a while - or he would be aware that Hungarian Notation is now considered by many to be a "bad thing".

          Deja View - the feeling that you've seen this post before.

          Q 1 Reply Last reply
          0
          • P Pete OHanlon

            Hungarian notation? Good? Ooohhh boy. That's a contentious statement, and I assume that the teacher has been out of professional development for a while - or he would be aware that Hungarian Notation is now considered by many to be a "bad thing".

            Deja View - the feeling that you've seen this post before.

            Q Offline
            Q Offline
            QzRz
            wrote on last edited by
            #5

            Oh, I guess its not a good thing to trust your teachers then :( But if Hungarian isn't good, what can you suggest I should use instead? I would like to use what is best from the beginning so I dont have to change it when I get a job after i'm done in school. //QzRz

            P 1 Reply Last reply
            0
            • Q QzRz

              Oh, I guess its not a good thing to trust your teachers then :( But if Hungarian isn't good, what can you suggest I should use instead? I would like to use what is best from the beginning so I dont have to change it when I get a job after i'm done in school. //QzRz

              P Offline
              P Offline
              Pete OHanlon
              wrote on last edited by
              #6

              QzRz wrote:

              Oh, I guess its not a good thing to trust your teachers then

              Nope - that's not what I was saying. I was saying rather than accepting what he says as gospel, you think for yourself and question it. Just because I, or somebody else, says that something is so doesn't actually mean it is. Apply a healthy dose of scepticism and make sure that what is being said is actually true. For instance. You probably know that people in the Middle Ages thought that the earth was flat and that you could sail right off the end of the world. Well - that's wrong. They didn't think that. This was a "fact" put out in a book called The Life And Voyages Of Christopher Columbus by Washington Irving in 1828. Anyway - what should you use. Well, take a look at the samples posted in the MSDN and in various of the more reputable articles here on CodeProject and decide for yourself.

              Deja View - the feeling that you've seen this post before.

              Q 1 Reply Last reply
              0
              • P Pete OHanlon

                QzRz wrote:

                Oh, I guess its not a good thing to trust your teachers then

                Nope - that's not what I was saying. I was saying rather than accepting what he says as gospel, you think for yourself and question it. Just because I, or somebody else, says that something is so doesn't actually mean it is. Apply a healthy dose of scepticism and make sure that what is being said is actually true. For instance. You probably know that people in the Middle Ages thought that the earth was flat and that you could sail right off the end of the world. Well - that's wrong. They didn't think that. This was a "fact" put out in a book called The Life And Voyages Of Christopher Columbus by Washington Irving in 1828. Anyway - what should you use. Well, take a look at the samples posted in the MSDN and in various of the more reputable articles here on CodeProject and decide for yourself.

                Deja View - the feeling that you've seen this post before.

                Q Offline
                Q Offline
                QzRz
                wrote on last edited by
                #7

                Pete O`Hanlon wrote:

                Nope - that's not what I was saying. I was saying rather than accepting what he says as gospel, you think for yourself and question it. Just because I, or somebody else, says that something is so doesn't actually mean it is. Apply a healthy dose of scepticism and make sure that what is being said is actually true.

                It was my choice of word which was bad, ofcause I will have to do as you write it. But starting up as new in the coding stuff it is hard to see which names is the best, therefore you kind of trust everything the teacher say. So if he says he think the Hungarian is the best, you will think it is too. But he didnt force us to use it, he just told us it was what he think was the best, and what he used himself. So if you look at the blackboard and on every other student using the Hungarian naming its a little hard not to use the same. But I know, as long as I use the same naming notation all over my files it should be good too, however I think it would be best if I could use the naming notation which most people already use. I just made a quick search over the internet and I found a few pages which says the same as you wrote in the first reply, the hungarian is out-dated. So I will keep searching untill I found something which will be in my taste :) I will thank you for helping me, I am really glad that people will use time to help new people :) Just 1 last question, do you have any good forums/sites which discuss all these "new things"?

                P 1 Reply Last reply
                0
                • Q QzRz

                  Pete O`Hanlon wrote:

                  Nope - that's not what I was saying. I was saying rather than accepting what he says as gospel, you think for yourself and question it. Just because I, or somebody else, says that something is so doesn't actually mean it is. Apply a healthy dose of scepticism and make sure that what is being said is actually true.

                  It was my choice of word which was bad, ofcause I will have to do as you write it. But starting up as new in the coding stuff it is hard to see which names is the best, therefore you kind of trust everything the teacher say. So if he says he think the Hungarian is the best, you will think it is too. But he didnt force us to use it, he just told us it was what he think was the best, and what he used himself. So if you look at the blackboard and on every other student using the Hungarian naming its a little hard not to use the same. But I know, as long as I use the same naming notation all over my files it should be good too, however I think it would be best if I could use the naming notation which most people already use. I just made a quick search over the internet and I found a few pages which says the same as you wrote in the first reply, the hungarian is out-dated. So I will keep searching untill I found something which will be in my taste :) I will thank you for helping me, I am really glad that people will use time to help new people :) Just 1 last question, do you have any good forums/sites which discuss all these "new things"?

                  P Offline
                  P Offline
                  Pete OHanlon
                  wrote on last edited by
                  #8

                  QzRz wrote:

                  It was my choice of word which was bad, ofcause I will have to do as you write it.

                  Good for you. Thinking for yourself is the first stage to becoming good at a subject.

                  QzRz wrote:

                  Just 1 last question, do you have any good forums/sites which discuss all these "new things"?

                  Hop on over to the Lounge and ask this question. There you will find many many people with strong opinions on this subject and they will debate it out right in front of you.

                  Deja View - the feeling that you've seen this post before.

                  O 1 Reply Last reply
                  0
                  • P Pete OHanlon

                    QzRz wrote:

                    It was my choice of word which was bad, ofcause I will have to do as you write it.

                    Good for you. Thinking for yourself is the first stage to becoming good at a subject.

                    QzRz wrote:

                    Just 1 last question, do you have any good forums/sites which discuss all these "new things"?

                    Hop on over to the Lounge and ask this question. There you will find many many people with strong opinions on this subject and they will debate it out right in front of you.

                    Deja View - the feeling that you've seen this post before.

                    O Offline
                    O Offline
                    originSH
                    wrote on last edited by
                    #9

                    Pete O`Hanlon wrote:

                    and they will debate it out right in front of you.

                    at length :P wether you want them to or not :P

                    1 Reply Last reply
                    0
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    • Login

                    • Don't have an account? Register

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • World
                    • Users
                    • Groups