If you are a frequent user of the Orchestrator Runbook Activity “Map Network Drive” you maybe sometimes have problems with that the path is already mapped with another Activity. It could be, for example, that another Runbook is mapping it with a different account. The result could be that the Activity fails and if you do not have a link that handles this the Runbook will stop at this Activity.
One way of solving this is to check if the drive is already mapped with the PowerShell command “Test-Path”. By doing so you can decide if you want to skip the “Map Network Drive” or if you want to disconnect the drive before mapping it again with the Runbook.
Below is an example on how to skip mapping it if already mapped.
The example Runbook
Below you can see some of the Activities.
Below you can see the link “Not Mapped”. The link “Mapped” is almost the same but have the Result set to “True”.