createfileextention.txt
来自「一部分关于VB编程的小技巧」· 文本 代码 · 共 21 行
TXT
21 行
Option Explicit
Sub CreateAssociations()
On Error Resume Next
savestring HKEY_CLASSES_ROOT, "\.pcs", "", "Saved_File"
savestring HKEY_CLASSES_ROOT, "\Saved_File", "", "Your File Description"
savestring HKEY_CLASSES_ROOT, "\Saved_File\shell\Open\command", "", App.Path & "\" & App.EXEName & " " & Chr(34) & "%1" & Chr(34)
savestring HKEY_CLASSES_ROOT, "\Saved_File\DefaultIcon", "", App.Path & "\" & App.EXEName & ",1"
End Sub
'see the part "Saved_File" change
'that to a description of your file type. And
'".pcs", change that to your extention.
'This will also give the files the main icon of
'the program, if you want store more icons in
'the program and change the ",1" to ",#"
'# being the icon number in the order you
'put them in the program.
'Include registry Module!
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?