title: Deployment package for a 64-bit windows service in VS2010
body: <p>I'm trying to create a deployment package for a windows service targeting x64.</p>
  
  <p>I've made the setup project itself target x64 but I need to add custom actions to actually register/unregister the service.</p>
  
  <p>However, when I add custom actions and try to run the installer, I get a <code>BadFormat</code> exception which indicates that the executable for my service is corrupted.</p>
  
  <p>I suspect I'm running into the <a href="http://blogs.msdn.com/b/heaths/archive/2006/02/01/64-bit-managed-custom-actions-with-visual-studio.aspx" rel="nofollow">issue mentioned here</a> but am unable to prove it.</p>
  
  <p>This windows service is being developed as part of a far larger application using TFS for automated builds and deployment, continuous integration, etc - So manually tweaking bits of a binary file using tools which require the use of a GUI is a definite no-no.</p>
  
  <p>So... What I need to know is; Is it possible to automatically build a deployment package for a 64-bit windows service in VS2010? If so how?</p>