Computer poisoning u disk so the file is hidden and cannot be set as visible

Source: Internet
Author: User

@echo off&setlocal enableextensions enabledelayedexpansion
title resolves a problem batch that cannot be modified by the folder hidden property
If "%~1" = "" (Echo you did not drag into any disk or file or folder!)
echo------
echo please drag the disk or file or folder you want to process onto the batch file icon
echo instead of double-click Start Batch!&pause&goto:eof)
Call:choose "Set hidden file properties, select:" Do not change the Remove settings
(Set h=) & (if!c! equ 2 set h=-) & (if!c! equ 3 set h=+)
Call:choose "Set the System file properties, select:" Do not change the Remove settings
(Set s=) & (if!c! equ 2 set s=-) & (if!c! equ 3 set s=+)
Call:choose "Set Application scope, select:" File or folder itself property and first level directory Content Properties folder first level directory content properties
For%%i in (%*) do (if!c! equ 1 call:attrib "%%~i"
for/f "delims="%%j in (' dir/a/b '%%~i "') do Call:attrib"%%~i\%%~j ")
Pause&goto:eof
: Choose
(Set c=) & (set n=) &for%%i in (%*) do echo!n! %%~i&set/a n+=1
(set/p c=) & (set/a c=c) &if!c! Geq 0 if!c! Leq!n! Echo.&goto:eof
Goto Choose
: attrib
setlocal& (Set a=) & (set A=%~A1) &if "!a!" = = "" Goto:eof
If not defined H if "!a:~3,1!" = = "H" (set h=+) Else (set h=-)
If not defined S if "!a:~4,1!" = = "S" (set s=+) Else (set s=-)
echo is processing:%~1&attrib!h!h!s!s "%~1" &goto:eof
Echo Modified successfully!

Computer poisoning u disk so the file is hidden and cannot be set as visible

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.