Package Installation or Update Fails with an Error
- 2 minutes to read
When you install or update DevExpress Blazor packages, you may encounter the Could not find a part of the path error followed by a long file path. This usually happens when the path exceeds Windows’ 260-character limit.
To resolve this issue, use one of the following methods:
Enable Long Path Support in Windows
Enable long path support in Windows to remove the path length limitation in Windows 10 (v1607+) and Windows Server 2016+. You can do this via the Registry Editor or Group Policy Editor.
Registry Editor (All Windows Editions):
- Open the Registry Editor.
- Navigate to
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem
key. - In the right pane, look for a
DWORD (32-bit)
value namedLongPathsEnabled
. If it does not exist, create it. - Set
LongPathsEnabled
to1
. - Restart your computer for the change to take effect.
Group Policy Editor (Windows Server, Windows 10/11 Pro, Enterprise, and Education)
- Open the Local Group Policy Editor.
- Navigate to Computer Configuration > Administrative Templates > System > Filesystem.
- Enable the Enable Win32 long paths setting.
- Restart your computer for the change to take effect.
Shorten the Project Path
Move your entire solution to a folder closer to the root of your drive, such as C:\Dev\
. This reduces the overall length of file paths during package installation.
Install the Failed Package Globally
If the failed package is DevExpress Blazor Template Gallery (DevExpress.Blazor.ProjectTemplates
), install it globally. This makes the templates available for all new projects.
Open a command prompt and run the following command:
dotnet new install DevExpress.Blazor.ProjectTemplates