0

I have a project, written in C#, which I want to deploy on a XP machine (target platform: .NET 4.0).

I dont seem to find an option to deploy (a.k.a generate an usable .exe file) in VS nowadays, so I'm guessing I'm ok with taking the executable in the debugfolder (bin/debug/). Doesnt feel very professional, but its the only executable I can find. When I move the executable to another folder and leave all the rest files in the debugfolder. I can run this app. But as fast as I try to use this file on another computer it crashes before its started.

I've installed .NET 4.0 Framework on the XP machine I want to run on. But it doesnt work. So then my question leads back on to how I was deploying this. Is there a better way? How are you suppose to extract the .exe file?

Also, is there anything else anyone of you can think of, at the top of your heads, that is required on the host machine - other than the framework?

Thanks in advance,

Dave

DaveL
  • 77
  • 1
  • 4
  • 13
  • FWIW .NET 4.5 isn't supported on XP: [Is it possible to run a .net 4.5 app on XP?](http://stackoverflow.com/questions/17499351/is-it-possible-to-run-a-net-4-5-app-on-xp) – chue x Apr 15 '14 at 14:19
  • What does this even mean? - "I dont seem to find an option to deploy (a.k.a generate an usable .exe file) in VS nowadays." If you build the project in release mode you will get a release exe. – bobbyalex Apr 16 '14 at 06:13
  • You will need all the dependency assemblies, in case you have any. Is this your first time coding, if you don't mind me asking? – bobbyalex Apr 16 '14 at 06:14
  • The .exe file in my build folder does work on my computer, but noone else. I took for granted that all the dependencies were in the release folder? – DaveL Apr 16 '14 at 06:30
  • @BobbyAlexander No this isnt my first time coding. Why is that even relevant? – DaveL Apr 16 '14 at 06:32
  • I asked that because you were taking your production assembly from the debug folder. – bobbyalex Apr 16 '14 at 06:35
  • Well, I was asking a question about it. A couple of years ago, you had an option for this in VS and dont have now - and therefore I ask. You dont contribute on this at all. And for some reason I suspect it isnt the first time. If I programmed before or not, is not an issue here. Grow up – DaveL Apr 16 '14 at 06:43

1 Answers1

1

In 'full' versions of Visual Studio there is a project template used for Installer creation. 2013 PRO has Installshield Limited Edition project template.

Unfortunately, such option is missing in express edition. So looks like the possible options for you are:

  1. Install trial version of VS2013 PRO and create installer.
  2. Use MS utility called WIX: http://en.wikipedia.org/wiki/WiX
  3. Use third-party add-in or application for packaging/installer creation, like:

You should also ensure that your app is searching for its libs and other dependencies in correct place - it's usually relative to .exe file location. Hope that helps.

sleepwalker
  • 1,032
  • 1
  • 9
  • 15