79633823

Date: 2025-05-22 13:14:07
Score: 1.5
Natty:
Report link

As already noted, New-PSDrive doesn't do that. When you run net use afterwards, you can't see those mapped drives either. At the time of this writing, probably the best cmdlet to use is New-SMBMapping, which does actually map the drives properly. Again, to test that, after running the cmdlet, try using the net use command and see whether the drives have been mapped.

Currently, my problem is that, while those drives do show up in net use, they don't seem to show up in Windows File Explorer. I'm trying to figure that out.

As for why it doesn't work when mapping drives as a privileged user, think of it like this: When you open the Command Prompt or PowerShell as a privileged user, your default location becomes C:\Windows\System32 instead of your home folder. Why is that? Well it's because you're no longer functioning as your own logged-in user. You're functioning as the administrator. So when you map your drives that way, even with net use, you're doing so in the administrator's context, not yours. To map drives in your own context, you need to do it as you.

Reasons:
  • RegEx Blacklisted phrase (0.5): Why is that
  • Long answer (-1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Low reputation (1):
Posted by: WNets