How to disconnect Network Drive

Hi all , i am working with Mapping a drive and moving a file from the drive to local desktop but before Mapping i will have to disconnect the existing Mapped Drives otherwise the Bot would throw an error since there is a Drive already existing with same name, How can I disconnect the Drive ? There is no code for disconnecting drives, please help.

Thanks in advance.

Have you tried command prompt?

net use B: /delete

hey @shaileshpathak

In short just use this

net use /delete *

it will release all mapped drives from your system. even if some of them are hidden and opened in the explorer as well. Let me know the updates.

U can use Invoke PowerShell activity.


Hey @aksh1yadav - used the same, its working !! Thanks :smiley:

Yes, it worked . Thanks :smiley:

Hello Team,
how to connect alredy mapped network drive,can you please help me on this .
Raj kumar

I also have same query… How to re-connect already mapped Network Drive which got disconnected.?