No announcement yet.

Windows - Shell extension doesn't work with very long paths

  • Filter
  • Time
  • Show
Clear All
new posts

  • Windows - Shell extension doesn't work with very long paths


    I've noticed that the shell extension doesn't work with files that are located in folders that have a total path of more that 1603 characters.

    These are the steps to reproduce.
    You should use an alternative file manager since Explorer won't be able to perform all the steps.

    - Go on a drive root like C:\

    - Create 7 nested directories, each 200 characters long.

    - Create one last nested directory 193 characters long.

    - Inside this folder create a couple of files.
    They can be empty and the name length doesn't change the result.

    - Select these two files and you'll see that the context menu works correctly.
    Meaning that there is the "Compare" option from Beyond Compare.

    Now if you rename the last folder to be one character (or more) longer you'll see that the "Compare" option isn't there anymore.

    The 1603 limit comes from 3 (drive root) + 7 * 201 (adding trailing backslashes) + 193.

    This is still a generous limit, however it would be nice if the extension could work with longer paths.
    Ideally up to, more or less, the 32,768 NTFS limit.

    Interestingly enough Beyond Compare works fine if I just drag and drop the files.
    But not if I try to open them via the menu.

    Also I noticed that Windows Explorer can't enter inside the last folder if it's 194 characters long, but works fine with 193 characters.
    Maybe these two limits are related.

    However I have another application that uses a similar shell extension that doesn't "disappear" with paths longer that 1063 characters.

    I tried this on Windows 7 x64 SP1 and Beyond Compare 4.0.7 (trial).

  • #2

    I recreated this folder structure, but on my machine I am unable to rename and navigate into Explorer once I add the extra one character. Since this is beyond the limit that Explorer can navigate, Windows shell extension would also be expected to have issues and fail. I am unsure how you are able to load the folder beyond Window's length limit within Explorer in order to see the context menu.

    BC4 itself can browse at a deeper level than Explorer, and from the Folder Compare our own right-click menu items continue to work on the selected items: Quick Compare would act on a selection of any two files and allow you to context menu compare them. It is usually not recommended to maintain paths greater than the host OS can support, but we are able to help if you are beyond this limit.
    Aaron P Scooter Software