1.autorun.inf例子
利用autorun.inf自动运行exe文件和修改图标格式有以下两种:
方法1:
[autorun]
OPEN=a.exe
ICON=a.ico
方法2:
[autorun]
OPEN=a.exe
shellexecute=a.exe
shell\Auto\command=a.exe
利用autorun.inf自动运行exe文件和修改图标格式有以下两种:
方法1:
[autorun]
OPEN=a.exe
ICON=a.ico
方法2:
[autorun]
OPEN=a.exe
shellexecute=a.exe
shell\Auto\command=a.exe
实际编写时,可新建txt文件,输入以上内容后,直接另存为inf文件即可
这里ico图标的显示还有另外一种写法:
[autorun]
OPEN=a.exe
ICON="a.exe,0"
即使用a.exe自身显示的图标
2.语法解释
1)OPEN与shellexecute都是执行可执行文件,但是OPEN只能跟exe,bat,com可执行文件,shellexecute可以是任意格式文件,最终的效果都是插入电脑后,弹出的框中第一行会多一行“运行 ***”
2)shell\Auto\command=a.exe含义是右键菜单会多出Auto选项,点击后执行a.exe