Untitled

 avatar
unknown
plain_text
2 months ago
445 B
4
Indexable
clear-host

$csvinhoud = Import-Csv C:\mappen.csv -Delimiter ","

foreach($i in $csvinhoud){
    $pad = $i."Pad"
    $omschr = $i.'Omschrijving '
    $fullpad = "$pad" + " " + "(" +$omschr+ ")"
    $testpath = Test-Path -Path $fullpad
    if($testpath){
        Write-Host "Map bestaat reeds: $fullpad"
    
    }
    else{
    New-Item $fullpad -ItemType Directory | Out-Null
    Write-Host "Map aangemaakt: $fullpad"
    }
}
Editor is loading...
Leave a Comment