我尝试在回复用户的时间之后制作一个.bat文件以关闭电脑,但不能正常工作:
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/BuildConfig.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/MainActivity.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R$attr.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R$dimen.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R$id.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R$layout.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R$menu.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R$mipmap.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R$string.class
[2016-07-03 02:40:59 - Test1] Dx
PARSE ERROR:
[2016-07-03 02:40:59 - Test1] Dx unsupported class file version 52.0
...while parsing com/example/test1/R$style.class
[2016-07-03 02:40:59 - Test1] Dx 11 errors; aborting
[2016-07-03 02:40:59 - Test1] Conversion to Dalvik format failed with error 1
什么都没发生(我以管理员权限运行)
怎么了?
答案 0 :(得分:1)
SET /P /A temp_var=set time to shutdown:
您不能同时将/p
和/a
与set
同时使用。选择其中之一。
Syntax
SET variable
SET variable=string
SET /A "variable=expression"
SET "variable="
SET /P variable=[promptString]
SET "
来源set
在您的情况下,您似乎只需要使用set /p
start "" shutdown -s -f -t %temp_var
批处理文件中的变量名称在每端都以%
分隔。
变量双方都有百分号:%ThisIsAVariable%
将%temp_var
替换为%temp_var%
。
更正了批处理文件:
SET /P temp_var=set time to shutdown:
start "" shutdown -s -f -t %temp_var%
exit