------ Start Script --------------------------------------------------------
#Folder Path
$FolderPath = "D:Test1"
#Check if folder exists
If (Test-Path $FolderPath) {
# Folder not exist, delete it!
Remove-Item -Path $FolderPath -Recurse
Write-host "Folder Deleted at '$FolderPath'!" -f Green
}
Else {
Write-host "Folder '$FolderPath' does not exists!" -f Red
}
------ End Script --------------------------------------------------------
ไม่มีความคิดเห็น:
แสดงความคิดเห็น