Quantcast
Channel: Active questions tagged windows - Super User
Viewing all articles
Browse latest Browse all 9128

Batch command with quotes fails to move files and delete folder with special characters

$
0
0

I have a custom batch program that I update and run to negate having to constantly waste half an hour just to clean up the Windows start menu every time I'm forced to reinstall Windows. It saves me a lot of hassle and I've got it pretty refined except there is one thing refusing to work.

Unlike literally every other shortcut (*.lnk) and directory, this does not work:

cd "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\AMD Software꞉ Adrenalin Edition"move "AMD Software꞉ Adrenalin Edition.lnk" "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\System\Settings"cd "C:\ProgramData\Microsoft\Windows\Start Menu\Programs"rmdir /S /Q "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\AMD Software꞉ Adrenalin Edition"

I know that the : character has special meaning and that is why the NTFS file system doesn't allow it's use. So whoever was in charge of the installer felt very compelled to use a similar character: modifier letter colon (U+A789).

How do I modify my batch program to move the file and delete the parent directory?


Viewing all articles
Browse latest Browse all 9128

Trending Articles