SCHTASKS 执行计划任务

CrossPython / 2023-08-27 / 原文

不正确:

schtasks /create /tn "MySQL Automatic Backup"
/tr "d:\path with spaces to my script\my script.bat" /sc daily ...

 

 

正确:

schtasks /create /tn "MySQL Automatic Backup"
/tr "\"d:\path with spaces to my script\my script.bat\"" /sc daily ...