daily pastebin goal
95%
SHARE
TWEET

Untitled

a guest Mar 19th, 2019 52 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Get-ChildItem X:MyPath -Recurse -Force | Where { ($_.Attributes.ToString() -Split ", ") -Contains "Hidden" } | Select FullName
  2.      
  3. dir /ah file.ext >nul 2>nul && (
  4.   echo file.ext is hidden
  5. ) || (
  6.   echo file.ext is NOT hidden
  7. )
  8.      
  9. attrib file.ext | findstr "^....H" >nul && (
  10.   echo file.ext is hidden
  11. ) || (
  12.   echo file.ext is NOT hidden
  13. )
  14.      
  15. for %%F in (file.ext) do echo %%~aF | findstr "^...h" >nul 2>nul &&
  16.   echo file.ext is hidden
  17. ) || (
  18.   echo file.ext is NOT hidden
  19. )
  20.      
  21. for %%F in (file.ext) do set "attr=%%~aF"
  22. if %attr:~3,1% equ h (
  23.   echo file.ext is hidden
  24. ) else (
  25.   echo file.ext is NOT hidden
  26. )
  27.      
  28. call :IsHidden file.ext &&
  29.   echo file.ext is hidden
  30. ) else (
  31.   echo file.ext is NOT hidden
  32. )
  33. exit /b
  34.  
  35. :isHidden
  36. echo %~a1 | findstr "^...h" >nul 2>nul
  37. exit /b
  38.      
  39. call :IsHidden file.ext &&
  40.   echo file.ext is hidden
  41. ) else (
  42.   echo file.ext is NOT hidden
  43. )
  44. exit /b
  45.  
  46. :isHidden
  47. setlocal
  48. set "att=%~a1"
  49. if %att:~3,1% equ h exit /b 0
  50. exit /b 0
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top