How to I run cmd as an administrator on a network drive?

Todd Chester 666 Reputation points
2022-11-20T12:23:31.297+00:00

Hi All,

If I open a cmd as an administrator, it won't let me change or see to any of my network drives. It is a real pain in the neck!

Is there something I can st to allow this?

Many thanks,
-T

Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,832 questions
0 comments No comments
{count} votes

Accepted answer
  1. MotoX80 32,566 Reputation points
    2022-11-20T13:34:39.99+00:00

    If your account has admin rights and you are just opening an elevated cmd prompt, you can create the EnableLinkedConnections registry entry to make them visible.

    https://learn.microsoft.com/en-us/troubleshoot/windows-client/networking/mapped-drives-not-available-from-elevated-command

    Detail to configure the EnableLinkedConnections registry entry

    In Registry Editor, locate and then click the following registry subkey:
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System

    Right-click Configuration, select New, and then select DWORD (32-bit) Value.

    Name the new registry entry as EnableLinkedConnections.

    Double-click the EnableLinkedConnections registry entry.

    In the Edit DWORD Value dialog box, type 1 in the Value data field, and then select OK.

    Exit Registry Editor, and then restart the computer.


1 additional answer

Sort by: Most helpful
  1. RLWA32 42,556 Reputation points
    2022-11-20T13:19:51.81+00:00

    Network drive mappings are per-user. If the account that you use to logon to Windows is not a member of the Administrators group then your elevated command prompt has been opened under a different user account (maybe the Administrator account?). That would explain why the mapped drives are not visible. You can map the drives in the elevated command prompt to make them visible. If you make the mapping persistent then they will be mapped every time the account used for the elevated command prompt is logged on.

    0 comments No comments