title: Remove-PSDrive does not remove drives
body: <p>I use Powershell > 4 to create and remove drives on my computer. I connect them locally to a folder or to remote drives:</p>
  
  <pre><code>New-PSDrive -Name L -PSProvider FileSystem -Root ($userprofile + "\Documents\whatever") -Scope Global -Persist
  New-PSDrive -Name I -PSProvider FileSystem -Root \\server\whatever -Scope Global -Persist -Credential $usercred
  </code></pre>
  
  <p>Now I would like to change the drives and disconnect them via:</p>
  
  <pre><code>Get-PSDrive -Name L, I -ErrorAction SilentlyContinue | Remove-PSDrive -Scope Global -Force
  </code></pre>
  
  <p>Without <code>-ErrorAction</code> I get the following message for the network drives which are currently not reachable:</p>
  
  <pre><code>Get-PSDrive : The drive was not found. A drive with the name "I" does not exist.
  In Zeile:1 Zeichen:1
  + Get-PSDrive -Name L, I -Scope  ...
  + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  + CategoryInfo : ObjectNotFound: (I:String) [Get-PSDrive], DriveNotFoundException
  + FullyQualifiedErrorId : GetDriveNoMatchingDrive,Microsoft.PowerShell.Commands.GetPSDriveCommand
  </code></pre>
  
  <p>Unfortunately, all drives (including L) are not removed or disconnected. I check this via <code>net use</code> and get:</p>
  
  <pre><code>Getrennt   I:   \\Server\whatever                    Microsoft Windows Network
  OK         L:   \\localhost\C$\...\Documents\wrong   Microsoft Windows Network
  </code></pre>
  
  <p>Do you have an idea why <code>Remove-PSDrive</code> does not do its job?</p>