Quantcast
Channel: The Official Scripting Guys Forum! forum
Viewing all articles
Browse latest Browse all 15028

How to make it sub folder ?

$
0
0
$folder  = "C:\test" #end param Get-FileMetaData -folder (gci e:\music -Recurse -Directory).FullName
 Get-ChildItem -path $folder -Recurse
Function funLine($strIN)  

  $strLine = "=" * $strIn.length 
  Write-Host -ForegroundColor Yellow "`n$strIN" 
  Write-Host -ForegroundColor Cyan $strLine 
} #end funline 
 
Function  funMetaData() 

 foreach($sFolder in $folder) 
  { 
   $a = 0 
   $objShell = New-Object -ComObject Shell.Application 
   $objFolder = $objShell.namespace($sFolder) 
 
   foreach ($strFileName in $objFolder.items()) 
    { FunLine( "$($strFileName.name)") 
      for ($a ; $a  -le 266; $a++) 
       {  
         if($objFolder.getDetailsOf($strFileName, $a)) 
           { 
             $hash += @{  
                   $($objFolder.getDetailsOf($objFolder.items, $a))  =
                   $($objFolder.getDetailsOf($strFileName, $a))  
                  } #end hash 
            $hash 
            $hash.clear() 
           } #end if 
       } #end for  
     $a=0 
    } #end foreach 
  } #end foreach 
} #end funMetadata  
 
# *** Entry Point *** 
 
funMetaData

Viewing all articles
Browse latest Browse all 15028

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>