My goal is create Windows mapped network drive in Windows to a WebDAV server.
Saved in Windows and they can be managed by using standard Windows tools, such as File Explorer
Https://Dopper12-test.sourcecloud.com/peet
I try this
New-PSDrive -Persist -Name “K” -PSProvider FileSystem -Root “\Dopper12-test.sourcecloud.com@SSL/peet” -Description “Cloud”
But i get the following error: New-PSDrive : The network resource type is not correct
Syntax of new New-PSDrive:
New-PSDrive [-Name] <String> [-PSProvider] <String> [-Root] <String> [-Confirm] [-Credential <PSCredential>] [-Description <String>]
[-Persist] [-Scope <String>] [-UseTransaction] [-WhatIf] [<CommonParameters>]
Your code:
New-PSDrive -Persist -Name “K” -PSProvider FileSystem -Root “\Dopper12-test.sourcecloud.com@SSL/peet” -Description “Cloud”
If you go through the help documentation, it clearly states that Name is a positional parameter with value 0, it should precede the -Persist parameter(and similarly you have to follow the Parameter-Set syntax rule to make the command run/work).