Board logo

标题: [注册表类] 批处理更改注册表值为何无效? [打印本页]

作者: pujizhongxue    时间: 2021-4-16 19:59     标题: 批处理更改注册表值为何无效?

我从注册表中导出了[HKEY_CLASSES_ROOT\Python.File\Shell\editwithidle\shell\edit37-32\command]
@="\"C:\\Users\\s\\AppData\\Local\\Programs\\Python\\Python37-32\\pythonw.exe\" -m idlelib \"%L\" %*",为了便于操作,我在批处理中使用了reg add "HKEY_CLASSES_ROOT\Python.File\Shell\editwithidle\shell\edit37-32\command" /ve /t REG_SZ /d "\"C:\\Users\\s\\AppData\\Local\\Programs\\Python\\Python37-32\\pythonw.exe\" -m idlelib \"%L\" %*" /f这一语句想把值"\"C:\\Users\\s\\AppData\\Local\\Programs\\Python\\Python37-32\\pythonw.exe\" -m idlelib \"%L\" %*"写入注册表,但是我遇到一个问题,如果像我这样写,导入的键值是"C:\\Users\\s\\AppData\\Local\\Programs\\Python\\Python37-32\\pythonw.exe" -m idlelib "*,请问这个问题该怎样解决?
作者: Batcher    时间: 2021-4-16 21:40

回复 1# pujizhongxue


参考:批处理修改注册表时的特殊字符转义
https://mp.weixin.qq.com/s/NY3mhVl1p8X4oARetooKmw




欢迎光临 批处理之家 (http://www.bathome.net/) Powered by Discuz! 7.2