修复文件关联的批处理问题。
文件内容如下:
assoc .exe=exefile
assoc .txt=txtfile
assoc .reg=regfile
assoc .com=comfile
assoc .bat=batfile
assoc .cmd=cmdfile
assoc .inf=inffile
assoc .vbs=vbsfile
ftype exefile="%%1" %*
ftype txtfile=%windir%\system32\notepad.exe %%1
ftype regfile=regedit.exe "%%1"
ftype comfile="%%1" %%*
ftype batfile="%%1" %%*
ftype cmdfile="%%1" %%*
ftype inffile=%systemroot%\system32\notepad.exe %%1
ftype vbsfile=%SystemRoot%\System32\WScript.exe "%%1" %%*
本来EXEFILE的话应该是exefile="%1" %*
为了解决%1在批处理中的特殊性,只好改成了exefile="%%1%" %%*
可是用批处理运行后,变成了exefile="%1" 后面的%* 不见了。
用引号括起来也不行,望高手解决,谢谢!
文件内容如下:
assoc .exe=exefile
assoc .txt=txtfile
assoc .reg=regfile
assoc .com=comfile
assoc .bat=batfile
assoc .cmd=cmdfile
assoc .inf=inffile
assoc .vbs=vbsfile
ftype exefile="%%1" %*
ftype txtfile=%windir%\system32\notepad.exe %%1
ftype regfile=regedit.exe "%%1"
ftype comfile="%%1" %%*
ftype batfile="%%1" %%*
ftype cmdfile="%%1" %%*
ftype inffile=%systemroot%\system32\notepad.exe %%1
ftype vbsfile=%SystemRoot%\System32\WScript.exe "%%1" %%*
本来EXEFILE的话应该是exefile="%1" %*
为了解决%1在批处理中的特殊性,只好改成了exefile="%%1%" %%*
可是用批处理运行后,变成了exefile="%1" 后面的%* 不见了。
用引号括起来也不行,望高手解决,谢谢!
