简体   繁体   English

在 windows 服务中以编程方式启用 Wol 设置

[英]Enable Wol settings programmatically in windows service

Is there any way to set the WOL(wake-on-lan) settings programmatically with c#?有没有办法使用 c# 以编程方式设置 WOL(wake-on-lan)设置? I've found few ways with powershell script but needed with c#.我发现 powershell 脚本的方法很少,但 c# 需要。

在此处输入图像描述

I need a way to check/uncheck the power management settings with c# in windows service.我需要一种方法来检查/取消检查 windows 服务中 c# 的电源管理设置。 Is it only possible by running powershell script with c#?是否只能通过使用 c# 运行 powershell 脚本来实现?

You can try starting the powershell script from c#您可以尝试从 c# 启动 powershell 脚本

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM