Need the switch that will make a net use z: /d command delete the z: drive connection even if the Z: drive has open files

I need the switch that will make a net use z: /d command delete the z: drive connection even if the Z: drive has open files.

Net use z: /d

What is the other switch (/) that I need to add that will delete the z: drive connection even if the z: drive has open files?
IT GuyNetwork EngineerAsked:
Who is Participating?
 
getzjdCommented:
Net use Z: /Delete /y   or net use Z: /delete /y >NUL
 
0
 
johnb6767Commented:
echo y | net use r: /del
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.