我面临一个奇怪的问题。我通过各种博客和教程创建了我的第一个 Windows 服务。然后为添加安装程序等创建设置。它在安装时工作正常,通过 Visual Studio 卸载但在我部署它时失败。
Below is a summary of the errors, details of these errors are listed later in the log.
* Activation of C:\Users\bhuvint\Documents\Visual Studio 2010\Projects\CPNS Library\ServicePackage\CommonPushNotificationWindowsService.application resulted in exception. Following failure messages were detected:
+ You cannot start application CommonPushNotificationWindowsService from this location because it is already installed from a different location.
+ You cannot start application CommonPushNotificationWindowsService from location file:///C:/Users/bhuvint/Documents/Visual%20Studio%202010/Projects/CPNS%20Library/ServicePackage/CommonPushNotificationWindowsService.application it is already installed from location file:///C:/inetpub/wwwroot/ServicePackage/CommonPushNotificationWindowsService.application. You can start it from location file:///C:/inetpub/wwwroot/ServicePackage/CommonPushNotificationWindowsService.application or you can uninstall it and reinstall it from location file:///C:/Users/bhuvint/Documents/Visual%20Studio%202010/Projects/CPNS%20Library/ServicePackage/CommonPushNotificationWindowsService.application.
我已经卸载了该服务并尝试从同一台 PC 中已部署的服务中安装它以进行测试。但它因上述错误而失败。 我觉得我以错误的方式部署了 Windows 服务。你们能否建议如何部署Windows服务? (我浏览过网络。所有人都建议从视觉工作室构建并安装它。但是如何发布它是我需要的东西。)
请尽快帮忙。