delphi-5mapped-drivetopendialog

Delphi - TOpenDialog does not show network mapped drives


I have an older app which was written with Delphi 5. It uses TOpenDialog for opening files. However, it does not show any of the mapped drives such as on the servers, only shows the physically attached drives like the C:\ drive or the USB flash drive. Is there a way to show shared network drives? If not, are there any alternatives that might do this?


Solution

  • It turned out that newer versions of Windows (10 and 11) apparently do not allow showing mapped drives unless specifically set.

    To address this, navigate in registry to:

    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System

    Create a new DWORD value called EnableLinkedConnections and set its value to 1.

    Restart the computer and then the mapped network drives will show in the dialog box with correct drive letters.