StrFile = "C:\Test.txt"
Set ObjWMI = CreateObject("Scripting.FileSysTemObject"
Set ObjFiles = ObjWMI .GetFile("C:\Test.txt")
If ObjFiles.Attributes And 1 Then
ObjFiles.Attributes = ObjFiles.Attributes Xor 1
End If
Set ObjWMI = Nothing
Set ObjFiles = Nothing