如何知道系统启动或关闭 [英] How to know system is start or off
问题描述
亲爱的朋友,
大家好,我在搞项目时遇到了一些问题。我想知道如何理解我的系统启动或关闭意味着我什么时候开始我的Windows 7或其他操作系统我怎么能理解这个操作系统在C#中启动或关闭。这是任何可用的dll所以我可以使用代码。
基本上我想要用于安全目的的代码。当我启动我的电脑然后自动发送消息在我的手机上,然后关机然后自动发送消息,所以如何理解系统是关机处理和系统启动。所以请给我信息是任何过程知道如何系统在C#中启动或关闭。
感谢高级!!
Dear Friend,
Hi everyone,I have some problem when implimenting project.I want to know how to understand my system is start or off means when i start my windows 7 or other operating system how can i understand this operating system start or shutdown in C#.Is any dll available so i can implimented code.
Basically i want to implimented code for security purposed.When i start my pc then automatically send message on my mobile and when shutdown then automatically send message so how to understand the system is shutdown processing and system is start.So please give me information is any process to know how to system is start or shutdown in C#.
Thanks in Advanced !!
推荐答案
试试System.Events
class
http://msdn.microsoft.com/en-us/library/microsoft.w in32.systemevents(v = vs.110).aspx [ ^ ]
Try theSystem.Events
class
http://msdn.microsoft.com/en-us/library/microsoft.win32.systemevents(v=vs.110).aspx[^]
这篇关于如何知道系统启动或关闭的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!