如何运行具有特定名称的空后台进程?
我想让某个进程始终在后台运行,这样就可以在 Windows 的任务管理器中查看它,并使用我给它指定的具体名称。
该进程实际上不应该做任何事情,我所关心的是每当我打开任务管理器并选择“进程”时查看进程名称。
实现此目的的一种方法是复制 Notepad.exe ,将其名称更改为某个名称,然后运行它。问题是我不想每次使用电脑时都打开记事本窗口。我需要它在后台运行。
如果有的话,我有 Windows 7。
谢谢。
I want to have a certain process always running in the background so it will be viewable in the Task Manager of windows, with the specific name I give it.
The process shouldn't do anything really, all I care about is to see the process name whenever I open the task manager and choose "processes".
One way to achieve this is to copy Notepad.exe , change its name to something and then run it. The problem is I don't want to have an open window of notepad everytime I'm using the PC. I need it to run on background.
If it matters, I have Windows 7.
Thank you.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
您正在寻找这样的东西:
这是最简单的 Windows 程序。它绝对不执行任何操作,也不消耗 CPU。
我无法想象你为什么想要它,但这就是你所描述的!
You are looking for something like this:
This is the most simple Windows program. It does absolutely nothing and does not consume CPU.
I can't imagine why you want it, but this is what you describe!
这是最小的 C# 版本:
您可以从命令行编译它:
csc /target:winexe MyProg.cs
Here's a minimal C# version:
You can compile this from the command line:
csc /target:winexe MyProg.cs
好吧,如果最小化的 DOS 窗口不打扰您,那么这个 DOS 命令将非常轻量并且可以为您完成工作:
start /min more
Well if a minimized DOS window doesn't bother you then this DOS command will be very light weight and will do the job for you:
start /min more