Windows 10: pathtoolongexception

Discus and support pathtoolongexception in Windows 10 Network and Sharing to solve the problem; I've recently run into problems while installing some programs and have been getting an error about paths exceeding 260 characters, after some quick... Discussion in 'Windows 10 Network and Sharing' started by Satellite Slickers, Mar 25, 2021.

  1. pathtoolongexception


    I've recently run into problems while installing some programs and have been getting an error about paths exceeding 260 characters,

    after some quick google searches ive tried to fix it by allowing long paths in the reg-edit only to discover that LongPathsEnabled in Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem has already been set to 1

    at this point I'm not quite sure what is going on or how to fix this,

    :)
     
    Satellite Slickers, Mar 25, 2021
    #1

  2. Can't Delete Folders

    I got this error:

    RMDIR : The specified path, file name, or both are too long. The fully qualified file name must be less than 260

    characters, and the directory name must be less than 248 characters.

    At line:1 char:1

    + RMDIR Desktop

    + ~~~~~~~~~~~~~~

    + CategoryInfo : WriteError: (C:\Users\admin\desktop\Desktop:String) [Remove-Item], PathTooLongException

    + FullyQualifiedErrorId : RemoveItemIOError,Microsoft.PowerShell.Commands.RemoveItemCommand
     
    ChristianVibora, Mar 25, 2021
    #2
  3. Not able to delete the contents of a specific location(The fully qualified file name must be less than 260 characters)

    Hi team,

    I'm trying to delete the content of specific cache location in my application but it's always failing.

    Command : Remove-Item "E:\Program Files\SAP BusinessObjects\tomcat\work\Catalina\*" -Recurse -Force

    Error :

    Remove-Item : The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less

    than 248 characters.

    At line:1 char:1

    + Remove-Item "E:\Program Files\SAP BusinessObjects\tomcat\work\Catalin ...

    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo : WriteError: (E:\Program File...alina\localhost:String) [Remove-Item], PathTooLongException

    + FullyQualifiedErrorId : RemoveItemIOError,Microsoft.PowerShell.Commands.RemoveItemCommand

    Kindly help me in getting the command to delete files with long paths.

    Regards,

    Manhoj
     
    ManhojViknesh, Mar 25, 2021
    #3
  4. pathtoolongexception

    File name too long when copying to a directory with shorter file path

    This is weird.

    I have a meanJs installation, the contents of which I copied to another folder.

    Original folder path: C:\work\defaults\mean_0.3.3

    File contents copied to: C:\work\defaults\a

    As you can see it's obvious that the file contents are copied to a folder with a shorter name, so the file name too long error should not come, yet it does.

    Is this a windows 10 bug?

    Tried to do the it with copy-item command on the powershell and this is part of the output (it goes on for a while):

     
    Ahmed-Anas, Mar 25, 2021
    #4
Thema:

pathtoolongexception