Windows Service application 初步探索
今天写了一个windows service程序, 本身这个程序是一个console application, 但是不能够通过F5直接运行, 会出现下面图片所示的错误:

提示说需要安装一个Instalutil.exe程序, 网上搜索了这个程序, 属于net framework中的一个自带的工具
1、打开运行 输入 cmd,按回车,输入cd C:\Windows\Microsoft.NET\Framework\v4.0.30319,回车,然后输入InstallUtil.exe 运行该程序,运行之后会有一些介绍
2、输入 InstallUtil 后面输入你要安装的程序服务路径包括程序的全名,如:F:\flight\blanceService\blanceService.exe 回车
附上我运行之后的效果图:

此时在该程序所在的exe文件夹处执行cmd命令,

该程序会被运行.在程序管理器中可以看到这个程序.
Windows Service application 初步探索的更多相关文章
- Window服务程序(windows service application)如何调试
服务程序不能通过常规的按F5或F11的方式来进行调试和运行,也无法立即运行一个服务或逐步调试它的代码. 因此,你必须安装并启动你的服务,然后附属(attach)一个Debugger到这个服务的进程上.
- 如何利用mono把.net windows service程序迁移到linux上
How to migrate a .NET Windows Service application to Linux using mono? 写在最前:之所以用要把windows程序迁移到Linux上 ...
- A basic Windows service in C++ (CppWindowsService)
A basic Windows service in C++ (CppWindowsService) This code sample demonstrates creating a basic Wi ...
- [Windows Azure] Building worker role B (email sender) for the Windows Azure Email Service application - 5 of 5.
Building worker role B (email sender) for the Windows Azure Email Service application - 5 of 5. This ...
- [Windows Azure] Building worker role A (email scheduler) for the Windows Azure Email Service application - 4 of 5.
Building worker role A (email scheduler) for the Windows Azure Email Service application - 4 of 5. T ...
- [Windows Azure] Building the web role for the Windows Azure Email Service application - 3 of 5
Building the web role for the Windows Azure Email Service application - 3 of 5. This is the third tu ...
- [Windows Azure] Configuring and Deploying the Windows Azure Email Service application - 2 of 5
Configuring and Deploying the Windows Azure Email Service application - 2 of 5 This is the second tu ...
- 如何托管ASP.NET Core应用到Windows Service中
(此文章同时发表在本人微信公众号"dotNET开发经验谈",欢迎右边二维码来关注.) 题记:正在构思一个中间件的设计,考虑是否既可以使用最新的技术,也可以兼顾传统的部署模式.所以有 ...
- NoSQL初探之人人都爱Redis:(4)Redis主从复制架构初步探索
一.主从复制架构简介 通过前面几篇的介绍中,我们都是在单机上使用Redis进行相关的实践操作,从本篇起,我们将初步探索一下Redis的集群,而集群中最经典的架构便是主从复制架构.那么,我们首先来了解一 ...
随机推荐
- qDeleteAll 之后必须清空容器
[1]qDeleteAll应用示例 qDeleteAll源码如下: template <typename ForwardIterator> Q_OUTOFLINE_TEMPLATE voi ...
- spring4.0.0 源码导入eclipse(sts)
其余步骤请见:http://www.cnblogs.com/xiluhua/p/7450972.html 执行 gradle eclipse -x :eclipse 报错: 解决办法: 找到 行,注释 ...
- HDU 2176 取(m堆)石子游戏 (尼姆博奕)
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2176 m堆石子,两人轮流取.只能在1堆中取.取完者胜.先取者负输出No.先取者胜输出Yes,然后输出怎 ...
- 听 Fabien Potencier 谈Symfony2 之 《What is Dependency Injection ?》
听 Fabien Potencier 谈Symfony2 之 <What is Dependency Injection ?> 什么是依赖注入?从PHP实现角度来分析依赖注入,因为PH ...
- win10 校园宽带连接不上的解决办法(错误720、“以太网”没有有效的ip设置)
遇到的问题如下图所示: 插上宽带后,查看以太网状态显示如下: 创建新连接宽带(PPPoE)(R)后,连接失败,错误为720,显示如下: 以太网网络诊断后,结果显示“以太网”没有有效的Ip设置,如下图所 ...
- js 简易时钟
html部分 <div id="clock"> </div> css部分 #clock{ width:600px ; text-align: center; ...
- Kali linux vim使用命令笔记
Kali Linux系统的vi编辑器/vim编辑器的使用和CentOS有很多不同.基本使用方法如下 1.vi的基本概念 基本上vi可以分为三种状态,分别是命令模式(command mode).插入模式 ...
- 柳暗花明又一村的———for循环
学习过了do while循环和while循环后,我们终于剩下了循环结构重的最后一个-------for循环 本人认为for循环相比于do while ,while而言.好学一点下面就是我对for循环的 ...
- Selenium在Firefox中踩过的
本文转至 http://www.51testing.com/html/11/n-3711311.html,作者对webdriver在Firefox中设置profile配置项挺熟的,是用Python实现 ...
- An Example of How Oracle Works
Oracle是怎么工作的,摘自Oracle 9i的官方文档 The following example describes the most basic level of operations tha ...