Use Robocopy, or "Robust File Copy"
This is a command-line directory replication command. It has been available as part of the Windows Resource Kit starting with Windows NT 4.0, and was introduced as a standard feature of Windows Vista, Windows 7 and Windows Server 2008.
Robocopy can be downloaded from http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=17657
The following batch file can do the job. Keep the batch file in your path.
DelFolder.bat
@echo off
if {%1}=={} @echo Syntax: DelFolder FolderPath&goto :EOF
if not exist %1 @echo Syntax: DelFolder FolderPath - %1 NOT found.&goto :EOF
setlocal
set folder=%1
set MT="%TEMP%\DelFolder_%RANDOM%"
MD %MT%
RoboCopy %MT% %folder% /MIR
RD /S /Q %MT%
RD /S /Q %folder%
endlocal
Comments
http://PathTooDeep.com
All you need to do is to download this program online and save all the settings to your computer. This program is compatible with Windows NT, 2000, XP, Vista and Windows 7. Create an icon for the Long Path Tool on your desktop for easy access. Each time you would
like to manage files that have a long filename all you need to do is to click the icon and it will instantly direct you to a window that presents all your files.Here you can rename, delete, open and move your files instantly without the worries of error messages saying that there is some sort of a problem.