Tech Off Thread

4 posts

Forum Read Only

This forum has been made read only by the site admins. No new threads or comments can be added.

VS 2005 C# - add item class is internal by default?

Back to Forum: Tech Off
  • User profile image
    JParrish

    It's finally annoyed me enough that I was wondering what the deal with making the classes added to a project with "Add New Item" internal by default? Is that supposed to force me to be a good little programmer? Is there a way to switch it to be public by default? I create far more public classes than internal. </rant>

  • User profile image
    TommyCarlier

    You can customize the templates of new items. Just go to "C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\ItemTemplates\CSharp\1033", unzip Class.zip, edit the C#-file, and rezip Class.zip.

  • User profile image
    TommyCarlier

    I see there's also a folder "C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\ItemTemplatesCache\CSharp\1033" that contains cached versions of the item templates. You'll probably have to remove the folder Class.zip, or edit the content.

  • User profile image
    JChung2006

    They probably did that, because they realized that most newbies would try to make everything as public as possible so that they wouldn't have to think about scope, aka the Global variable syndrome.

Conversation locked

This conversation has been locked by the site admins. No new comments can be made.