本帖最后由 zhangop9 于 2012-1-17 16:23 编辑
根据剪切板内容重命名当前文件,能用一行mshta代码搞定吗?
想达到的效果:http://bbs.bathome.net/thread-14771-1-2.html
想加入注册表中,如这样- REGEDIT4
-
- [HKEY_CLASSES_ROOT\.bat\ShellNew]
- "command"="mshta vbscript:Execute(\"CreateObject(\"\"Scripting.FileSystemObject\"\").OpenTextFile(\"\"%2\"\",2,true).Write(clipboardData.getData(\"\"text\"\")):close\")"
- [HKEY_CLASSES_ROOT\.reg\ShellNew]
- "command"="mshta vbscript:Execute(\"CreateObject(\"\"Scripting.FileSystemObject\"\").OpenTextFile(\"\"%2\"\",2,true).Write(clipboardData.getData(\"\"text\"\")):close\")"
- [HKEY_CLASSES_ROOT\.vbs\ShellNew]
- "command"="mshta vbscript:Execute(\"CreateObject(\"\"Scripting.FileSystemObject\"\").OpenTextFile(\"\"%2\"\",2,true).Write(clipboardData.getData(\"\"text\"\")):close\")"
复制代码 vista下无法运行vbs文件。 |