Command to Delete All Files Permanently with No Prompt

What parameters with the del command can I use to delete a folder, all of it's contents, for all file types (read-only, those with missing permissions, etc), permanently, and without a prompt to select yes or no.

Is this sufficient?

Del "Z:\FolderName" /f
LVL 1
fireguy1125Asked:
Who is Participating?
 
ktaczalaConnect With a Mentor Commented:
Use:

RMDIR [/S] [/Q] [drive:]path
RD [/S] [/Q] [drive:]path

    /S      Removes all directories and files in the specified directory
            in addition to the directory itself.  Used to remove a directory
            tree.

    /Q      Quiet mode, do not ask if ok to remove a directory tree with /S
0
 
aadihCommented:
/f is for force deleting of read-only files.

/q is for quiet mode, i.e., do not ask if ok to delete on global wildcard.
0
 
Steve KnightIT ConsultancyCommented:
if you dont have permissions to files it wont work still of course, will need to push permissions down and/or take ownership as usual.

steve
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.