📄 sol5-5.vbs
字号:
'set read-only and toggle hidden attribute for a file
Const ReadOnly = 1
Const Hidden = 2
Dim objFSO, objFile
Set objFSO = CreateObject("Scripting.FileSystemObject")
'get a reference to a file
Set objFile = objFSO.GetFile("e:\data\report.doc")
'set the Readonly attribute
objFile.Attributes = objFile.Attributes Or ReadOnly
'toggle the Hidden attribute
objFile.Attributes = objFile.Attributes Xor Hidden
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -