如何使用WMI运行远程bat文件 [英] How to use WMI to run a remote bat file
本文介绍了如何使用WMI运行远程bat文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想使用WMI运行位于远程计算机上的远程bat文件.我该怎么做.请帮助我,谢谢您.
解决方案
^ ].
第二个条目甚至在codeproject上(第一个条目是您的...)!
使用ManagementScope获取连接
然后创建ManagementClass
使用file.bat作为object [] cmdLine
中的参数 并运行InvokeMethod("Create",cmdLine);的方法
hi
I want to use WMI to run a remote bat file that is at remote machine. How can I do it. Please help me, thank you
解决方案
Try this one[^].
The second entry is even on codeproject (the first is yours...)!
Use ManagementScope get connection
and then create ManagementClass
use the file.bat as params in object[] cmdLine
and run method of InvokeMethod("Create",cmdLine);
这篇关于如何使用WMI运行远程bat文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文