Benjamin Ashton

Benjamin Ashton

  • NA
  • 15
  • 7.4k

C# NET2.0 Windows Service

Jul 18 2012 9:13 AM
I am trying to develop a Windows Service and am having problems actually installing the service, so any help would be appreciated. I have tried using all the versions of Framework on my machine, making sure the target is x86 and also changing the name of the project.

http://pastebin.com/tWe17P6G - The Service
http://pastebin.com/JZic5TCX  - The Installer
http://pastebin.com/i2Bkyytp  - The Installer BAT


The Error 
C:\Users\User\Desktop>service.bat
Microsoft (R) .NET Framework Installation utility Version 2.0.50727.5420
Copyright (c) Microsoft Corporation.  All rights reserved.

Exception occurred while initializing the installation:
System.BadImageFormatException: Could not load file or assembly 'file:///C:\User
s\User\Desktop\setup.exe' or one of its dependencies. The module was expected to
 contain an assembly manifest..
Install Done.

Thanks!