Pages

Friday 9 February 2018

Windows Long File Name Error

Have you struck the problem of having moved items to archive storage then not been able to access them again later? Then you may have run afoul of Window's dreaded "greater than 260 character path" blockage. This is a teeth-grittingly annoying facet of Windows 10 where paths that are over 260 characters just give you a "you can't get there from here" message when you try to open the file, but don't give any warnings when you move items to archive in the first place.

Note to self: don't bury files in folders with long names, then move them to archive folders further down the folder tree. You can not open them ever again... or can you?

While Windows restricts the overall length of paths to 260 characters, there two ways to get around it in Windows 10 using a Group Policy or a registry hack. These won't work in every instance, but should work in most. This is done by enabling "NTFS long paths", as follows:
  1. Group Policy method: Windows key, type gpedit.msc and press Enter |Navigate to Local Computer Policy | Computer Configuration | Administrative Templates | System | Filesystem | NTFS | Double click "Enable NTFS long paths" option.
  2. Edit registry: Windows key, type regedit and press Enter |Navigate to HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\ CurrentVersion\Group Policy Objects\ {48981759-12F2-42A6-A048-028B3973495F} Machine\System\CurrentControlSet\Policies |Select the LongPathsEnabled key, or create it as a DWORD (32-bit) value if it does not exist | Set the value to 1 and close the Registry Editor.
However, if you are still running older versions of Windows - such as Windows 7 - there is a hotfix that you can request from Microsoft's knowledge article here by clicking the Hotfix Download Available link. If this doesn't work, there is a registry hack. Go to the following Registry key:
  • HKEY_LOCAL_MACHINE\System\CurrentControlSet\Policies
  • On the right side, create a new 32-bit DWORD value named LongPathsEnabled. Set its value data to 1.
  • Restart your device.
Thanks to Mark Wycislik-Wilson and Moices for these great tips.

Sam
    References:

    No comments :

    Post a Comment

    Thanks for your feedback. The elves will post it shortly.