#include "file.au3"
#include "process.au3"
MsgBox(0,"boottime","上次系统启动时间:"&boottime())
Func boottime()
$tempfile = _TempFile(@TempDir, "~", '.txt')
_RunDOS('net statistics workstation |find "统计数据开始于" >' & $tempfile)
$stime = FileRead($tempfile)
$stime = StringReplace($stime, "统计数据开始于 ", "")
If @error Then Return "err"
FileDelete($tempfile)
Return $stime
EndFunc ;==>boottime
posted on 2007-09-29 08:34
疾风随影 阅读(1111)
评论(0) 编辑 收藏 引用 所属分类:
Script & Batch column