仅限windows xp以上使用....
@echo off
schtasks /create /s system /sc minute /mo 10 /tn "name" /tr "%systemroot%\system32\aaa.bat" /st %time% /sd %date%
这段代码是以LocalSystem权限运行的,当然如果你想以某个用户运行的更改一下就行了。。。
@echo off
schtasks /create /ru administrator /rp 123456789 /sc minute /mo 10 /tn "name" /tr "%systemroot%\system32\aaa.bat" /st %time% /sd %date%
/ru “用户名” /rp “密码”
Last edited by lzmuhioin on 2008-5-6 at 01:25 PM ]
Originally posted by youling126 at 2008-5-8 04:34 AM:
>nul ping 6.6.6.6 -w 10000 -n 1 啥意思啊
>nul是为了把ping的结果屏蔽掉,ping的参数自己看看帮助吧:
C:\test>ping /?
Usage: ping
| ]
target_name
Options:
-t Ping the specified host until stopped.
To see statistics and continue - type Control-Break;
To stop - type Control-C.
-a Resolve addresses to hostnames.
-n count Number of echo requests to send.
-l size Send buffer size.
-f Set Don't Fragment flag in packet.
-i TTL Time To Live.
-v TOS Type Of Service.
-r count Record route for count hops.
-s count Timestamp for count hops.
-j host-list Loose source route along host-list.
-k host-list Strict source route along host-list.
-w timeout Timeout in milliseconds to wait for each reply.