Visual c# compiler

I have programe a win application by c# and I install WSE on my computer to add reference server2 to do something, but I copy the debug folder to other computer to run my app, it shows error and then I install WSE on this computer it works, what should I do to set my complier to complie .exe that can run on any computer.
Who is Participating?
Carl TawnConnect With a Mentor Systems and Integration DeveloperCommented:
You need to set the "Active Configuration" for your project to "Release" before you compile. The debug version isn't intended to be distributed.

In the IDE, go to Project > YourApp Properties -> Build, there should be an option for "Configuration" change this to "Release".
The menu location above is based on Visual Studio 2005 so may be different for you. When you compile now you should get a Release folder which contains the EXE that can be distributed. Of course the target machine will still need .Net Framework.
All Courses

From novice to tech pro — start learning today.