강좌 / 팁

윈 도 우 file_folder2Hide&show, vbe <--> vbs

2020.04.03 15:32

레마클로 조회:631 추천:8

 

FF2HIDE.png

 

 

file_folder2Hide.7z

 

SendTo_copyfilefolder2Hide.vbs를 실행하여 ---file_folder2Hide---.vbs를 SendTo폴더에 복사

 

 

 

f2hs.gif

---file_folder2Hide---.vbs(투박하지만 작동함)

 

''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

Set Fso = CreateObject("Scripting.FileSystemObject")

Set Args = WScript.Arguments

 

If (Fso.FolderExists(Args(0))) Then 

            Set gFolder = Fso.GetFolder(Args(0))

            gDir = Fso.GetParentFolderName(gFolder) 

            strDir = gDir & "\s-h-o-w-FOLDER.vbs"

Set outFile = Fso.CreateTextFile(strDir, True)

outFile.WriteLine "Set Fso = CreateObject(""Scripting.FileSystemObject"")"

outFile.WriteLine "Set gFolder = Fso.GetFolder(""" & gFolder & """)"

outFile.WriteLine "gFolder.Attributes = gFolder.Attributes AND NOT 2"

outFile.WriteLine "Fso.DeleteFile Wscript.ScriptFullName, True"

outFile.WriteLine "Set Fso = nothing"

outFile.WriteLine "Set gFolder = nothing"

outFile.WriteLine "WScript.Quit"

outFile.Close

     gFolder.Attributes = gFolder.Attributes XOR 2

Else

            Set gFile = Fso.GetFile(Args(0))

            gDir = Fso.GetParentFolderName(gFile) 

            strDir = gDir & "\s-h-o-w-FILE.vbs"

Set outFile = Fso.CreateTextFile(strDir, True)

outFile.WriteLine "Set Fso = CreateObject(""Scripting.FileSystemObject"")"

outFile.WriteLine "Set gFile = Fso.GetFile(""" & gFile & """)"

outFile.WriteLine "gFile.Attributes = gFile.Attributes AND NOT 2"

outFile.WriteLine "Fso.DeleteFile Wscript.ScriptFullName, True"

outFile.WriteLine "Set Fso = nothing"

outFile.WriteLine "Set gFile= nothing"

outFile.WriteLine "WScript.Quit"

outFile.Close

     gFile.Attributes = gFile.Attributes XOR 2

End If

 

Set Fso = nothing

Set Args = nothing

Set gFolder = nothing

Set gFile= nothing

''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

 

 

 

============================

Set objFSO = CreateObject("Scripting.FileSystemObject")

Set objFile = objFSO.GetFile("C:\FSO\ScriptLog.txt")

 

If objFile.Attributes AND 0 Then

    Wscript.Echo "No attributes set."

End If    

If objFile.Attributes AND 1 Then

    Wscript.Echo "Read-only."

End If    

If objFile.Attributes AND 2 Then

    Wscript.Echo "Hidden file."

End If    

If objFile.Attributes AND 4 Then

    Wscript.Echo "System file."

End If   

If objFile.Attributes AND 32 Then

    Wscript.Echo "Archive bit set."

End If    

If objFile.Attributes AND 64 Then

    Wscript.Echo "Link or shortcut."

End If    

If objFile.Attributes AND 2048 Then

    Wscript.Echo "Compressed file."

End If

 

============================

 

If objFolder.Attributes AND 2 Then

    Wscript.Echo "Hidden folder."

End If    

If objFolder.Attributes AND 4 Then

    Wscript.Echo "System folder."

End If    

If objFolder.Attributes AND 16 Then

    Wscript.Echo "Folder."

End If  

If objFolder.Attributes AND 32 Then

    Wscript.Echo "Archive bit set."

End If

If objFolder.Attributes AND 2048 Then

    Wscript.Echo "Compressed folder."

End If

 

=========================

 

 

---Encode-vbs2vbe---.vbs와 ---Decode-vbe2vbs---

 

SendTo_copyEncodeDecodeVBSVBE.vbs를 실행하여 

      ---Encode-vbs2vbe---.vbs와 ---Decode-vbe2vbs---.vbs를 SendTo폴더에 복사

제가 만든 파일 아니고 외국자료입니다

 

[예] Svchost_reducer.vbe 마우스 우클릭 --> 보내기 --> "---Decode-vbe2vbs---.vbs" 클릭

 

f2hs2.png

 

 

 

번호 제목 글쓴이 조회 추천 등록일
[공지] 강좌 작성간 참고해주세요 gooddew - - -
561 윈 도 우| [초보용] 윈도 wim파일 교체하기 (ISO 편집) [11] suk 14807 8 08-25
560 윈 도 우| 윈8 종료버튼 타일에 등록하기 [1] 적광 14810 1 03-07
559 윈 도 우| 윈도우8 자동로그인 방법 [6] 아수스 14810 6 08-18
558 소프트웨어| XP IE8 "이탭은 복구 되었 습니다." 오류 복구 [16] Good Bye 14813 0 11-16
557 윈도7 7600 RTM 에서 인터넷 초고속으로 만들기.. [18] 정동원 14815 0 07-22
556 ASUS,LG....자동인증 씨디 만들기 [4] 왕대인 14834 0 10-13
555 Vista SP1(Service Pack 1) 설치 후 필요없는 파일 삭제로 ... [25] 김정행 14839 0 03-24
554 소프트웨어| PE로 부팅하여 윈도7 을 빠르게 설치하는 방법 [6] 해밀 14842 0 11-26
553 하드웨어| 본인의 Flash Player 버전 확인방법 [7] GoogleDotC 14849 1 02-18
552 하드웨어| IE8 일반적 오류 & mshtml.dll 오류 해결하기 [3] 강원 14860 1 09-04
551 서버 / IT| [팁:정보_수정] 미친 알약(ALyac) [12] 우금티 14870 0 12-21
550 윈 도 우| 윈도우 8, 갑자기 한글이 안쳐져요! IME가 먹통일때! 해결 팁! [10] 핑크맛우유 14877 1 10-02
549 하드웨어| -컴퓨터 최적화하기 1- [21] 납딱콩 14886 5 04-09
548 윈 도 우| 윈8 & 윈2012가 불편한 이유 - 해소 [IME 설정방법] [9] DuDu 14921 6 09-26
547 소프트웨어| VMware workstation 사용법(본문 수정-2) [76] 고양이2 14927 30 11-14
546 소프트웨어| pe의 wim을 vhd로 변경 [8] 카멜 14930 6 04-27
545 윈 도 우| 윈7 내장 캡처도구의 유용한 단축키 [3] 애벌레 14936 1 05-14
544 윈 도 우| [추가] usb 부팅, 외장하드 부팅, 울트라 iso로 다 되네요. [24] suk 14949 14 06-17
543 윈 도 우| [수정] Windows 8 Edition (SKU) 정리와 잘못된 상식 [4] 통나무 14965 1 08-19
542 하드웨어| 인텔 펌업 이미지를 USB 메모리로 부팅하기 [3] dogma01 14980 0 02-04
XE1.11.6 Layout1.4.8