강좌 / 팁

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

2020.04.03 15:32

레마클로 조회:632 추천: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 - - -
4481 소프트웨어| ▣▣▣▣▣[ Ventoy 고급 응용편 자료 정리 ]▣▣▣▣▣ [31] 메인보드 7885 57 05-14
4480 소프트웨어| USB 로 UEFI 와 MBR 로 부팅 되도록 ISO 파일 설치하기 [42] 좋은이웃 7089 57 03-17
4479 소프트웨어| rufus 3.18 사용법 (2가지) [24] suk 5960 55 03-14
4478 소프트웨어| PC 카카오톡 광고 제거 (6차 수정) [49] CraXicS 6668 55 05-29
4477 소프트웨어| Ventoy usb만들기 [41] 메인보드 6319 55 09-04
4476 윈 도 우| PE 드라이버 통합하기 V1.03 [41] 히이이잌 5320 53 02-09
4475 윈 도 우| 나만의 PE를 만들자 실전편 1탄(윈도우 10PE빌드하기) [174] 지연서연아 26477 51 08-27
4474 윈 도 우| 윈도우11 $OEM$소스 및 WinNTSetup 응용 설치! [40] 무월 3489 50 02-03
4473 소프트웨어| 램디스크(Ram Disk) 만들기 - 본문 수정 [60] 고양이2 9434 50 12-02
4472 기 타| WindowsXPE147 수정버전 사용법 입니다... [28] 노랑개굴 1977 49 03-11
4471 기 타| 구글 드라이브 다운로드 초과했을 때 다운로드 방법 [41] suk 26737 49 11-19
4470 소프트웨어| 다음 팟플레이어 광고[팝업] 차단 [12] 무월 3165 48 07-26
4469 윈 도 우| [실시간 보호 기능 켬/끔] 좀 더 편하게 실행 [25] 지후빠 3911 48 06-26
4468 윈 도 우| [실사] 단일 SSD(HDD)에서 윈도우 설치 하기! [20] 무월 4001 46 10-14
4467 소프트웨어| 크롬 하단 다운로드창 활성화 [11] 무월 2830 46 08-03
4466 윈 도 우| [1탄] install.wim 누적 업데이트 통합 하기 [26] 무월 1899 45 08-19
4465 윈 도 우| PrincePE_V21 [30] %카리스마 2449 45 03-06
4464 윈 도 우| 키만 6번 누르세요~ [121] 익덕이 9432 45 05-27
4463 기 타| 그 동안 본인이 업로드한 강좌를 보내드립니다. [181] 고양이2 12717 45 11-06
4462 소프트웨어| 한글 2020 제품키 자동 입력 및 업데이트 통합하기 [29] CraXicS 11122 44 02-06
XE1.11.6 Layout1.4.8