How to Change the Name of the Application File when Programming in C#

H. Gal
Changing the default application file name when working on a project in C# gives the code more readability and increases the cohesiveness of the overall program. For example, if you leave the default program name as "program.cs" it can apply to just about any C# application. Instead, if the name of your program is "Time Clock," consider renaming the program name "Timeclock.cs."

Open VisualStudio.NET. You'll see the starting page. Open a new project.

When the new project opens the blank screen, click on the "Solution Explorer" tab. If you do not see this tab, go up to "View" in the menu choices and click on it. Navigate to "Solution Explorer" to have it appear in the workspace.

Click on the file "program.cs." Click on the Properties tab. If you do not see the properties tab, go up to "View" in the menu choices and click on it. Navigate to "Properties" and click on it.Scroll down to the "File name" field and change the file name to match your project name and leave the ".cs" after it. Hit enter when you are finished.

It is not recommended that you change the application file name after you've already begun adding computer code to the project unless you are considered an expert programmer.

Published by H. Gal

H. Gal specializes in helping individuals and businesses get done what needs to be done now at prices they can afford. She has been writing for over 15 years for both online and offline publications and hold...  View profile

To comment, please sign in to your Yahoo! account, or sign up for a new account.