Tuesday, July 14, 2009

How do I get an executable out of my basic C# program in Visual Studio?

I'm a rookie at Visual Studio/.NET. I just coded my very first 'Hello World' C# program. It works fine within Visual Studio when I try to run it. I've tried build. I want my program to be a standalone .exe (executable) that I can run from a dos prompt. It's just a simple console application. What do I need to do (step by step) to get an executable version of it? What am I missing? All I have is the .cs source code. Thanks in advance.

How do I get an executable out of my basic C# program in Visual Studio?
If you can execute your application from visual studio then that means that you already have an .exe and Visual Studio simply runs it!





The .exe is located in the "bin/debug" or "bin/release" directory which is inside your project directory.


If you have Visual Studio 2003 the directory of your project is usually at "my documents/visual studio projects"


If you have visual studio 2005 it's usually at "my documents/visual studio 2005/projects"
Reply:compile it from the build menu. you might have to adjust your toolbars if its not showing up.


No comments:

Post a Comment