Go Back  DVD Talk Forum > General Discussions > Tech Talk
Reload this Page >

Help with deleting a folder that ends with a "." in XP

Tech Talk Discuss PC Hardware, Software, Internet and Other Technology

Help with deleting a folder that ends with a "." in XP

Old 02-17-13, 02:14 AM
  #1  
DVD Talk Platinum Edition
Thread Starter
 
JZ1276's Avatar
 
Join Date: Aug 2004
Location: Long Island
Posts: 3,534
Help with deleting a folder that ends with a "." in XP

I have a folder on my desktop that I mistakenly ended the name with a period and now I cannot delete it. I did a search and came up with this.

"Cause 6: The file name includes an invalid name in the Win32 name space
You may not be able to delete a file if the file name includes an invalid name (for example, the file name has a trailing space or a trailing period or the file name is made up of a space only). To resolve this issue, use a tool that uses the appropriate internal syntax to delete the file. You can use the "\\?\" syntax with some tools to operate on these files, for example:
del "\\?\c:\path_to_file_that contains a trailing space.txt "


Can someone please explain to me how to do this in terms I can understand?? Thanks!
JZ1276 is offline  
Old 02-17-13, 07:44 AM
  #2  
DVD Talk Legend
 
Join Date: Apr 2003
Location: Land of the Lobstrosities
Posts: 10,300
Re: Help with deleting a folder that ends with a "." in XP

First you need to figure out the path to the folder. Right click on it from the desktop and select Properties. On the first page will be the location, or path, to the folder. It will be something like "C:\users\JZ1276\desktop" . To get the full path you then just add a slash and the folder name like "\MyFolder." to the end of the location. So the full path will look like "C:\Users\JZ1276\Desktop\MyFolder."

Next, you need to get to the command prompt, which you can find in the start menu All Programs\Accessories

To remove the folder type:

rd /s "\\?\C:\Users\JZ1276\Desktop\MyFolder."

If it was a file you would type:

del "\\?\C:\Users\JZ1276\Desktop\MyFile."

Then hit enter.
wmansir is offline  
Old 02-17-13, 08:44 AM
  #3  
DVD Talk Legend
 
Nick Danger's Avatar
 
Join Date: Mar 2001
Location: Albuquerque
Posts: 21,965
Re: Help with deleting a folder that ends with a "." in XP

What is "\\?\" in DOS?

It looks like a wildcard, but I don't understand why he wants to use a wildcard before the root directory.
Nick Danger is offline  
Old 02-17-13, 11:39 AM
  #4  
DVD Talk Legend
 
Join Date: Apr 2003
Location: Land of the Lobstrosities
Posts: 10,300
Re: Help with deleting a folder that ends with a "." in XP

Originally Posted by Nick Danger View Post
What is "\\?\" in DOS?

It looks like a wildcard, but I don't understand why he wants to use a wildcard before the root directory.
That just indicates that the address is in unicode so it is treated differently than normal filename/path. It can be used to overcome limitations in Windows file handling like addresses that would contain illegal characters under Windows, contain reserved names, or are longer than the 260 character address limit.



Also, to the OP, have you tried renaming the folder?

Last edited by wmansir; 02-17-13 at 12:03 PM.
wmansir is offline  
Old 02-17-13, 02:42 PM
  #5  
DVD Talk Limited Edition
 
Join Date: Aug 2000
Location: DVDTalk's Surgeon General
Posts: 5,508
Re: Help with deleting a folder that ends with a "." in XP

Originally Posted by wmansir View Post
That just indicates that the address is in unicode so it is treated differently than normal filename/path. It can be used to overcome limitations in Windows file handling like addresses that would contain illegal characters under Windows, contain reserved names, or are longer than the 260 character address limit.



Also, to the OP, have you tried renaming the folder?


I am guessing that if you can't delete it you also can't rename it. But if this solves the problem then
shadowhawk2020 is offline  
Old 02-17-13, 05:37 PM
  #6  
DVD Talk Legend
 
Join Date: Apr 2003
Location: Land of the Lobstrosities
Posts: 10,300
Re: Help with deleting a folder that ends with a "." in XP

I just did a google search and saw that listed as a fix. I tried it in Win7 and it didn't work, either via right click->rename or changing the name on the properties page.
wmansir is offline  
Old 02-17-13, 06:18 PM
  #7  
DVD Talk Special Edition
 
danwiz's Avatar
 
Join Date: Dec 2000
Location: Fairbanks, Alaska
Posts: 1,849
Re: Help with deleting a folder that ends with a "." in XP

Use ZTreeWin and you can delete nearly anything.
danwiz is offline  
Old 02-17-13, 07:52 PM
  #8  
DVD Talk Platinum Edition
Thread Starter
 
JZ1276's Avatar
 
Join Date: Aug 2004
Location: Long Island
Posts: 3,534
Re: Help with deleting a folder that ends with a "." in XP

Originally Posted by wmansir View Post
First you need to figure out the path to the folder. Right click on it from the desktop and select Properties. On the first page will be the location, or path, to the folder. It will be something like "C:\users\JZ1276\desktop" . To get the full path you then just add a slash and the folder name like "\MyFolder." to the end of the location. So the full path will look like "C:\Users\JZ1276\Desktop\MyFolder."

Next, you need to get to the command prompt, which you can find in the start menu All Programs\Accessories

To remove the folder type:

rd /s "\\?\C:\Users\JZ1276\Desktop\MyFolder."

If it was a file you would type:

del "\\?\C:\Users\JZ1276\Desktop\MyFile."

Then hit enter.
Thank you. This worked. BTW, anyone that mentioned renaming, that was the first thing I tried. Said "could not read from source file or disc" (or something like that).
JZ1276 is offline  

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Thread Tools
Search this Thread

Archive Advertising Cookie Policy Privacy Statement Terms of Service

Copyright 2018 MH Sub I, LLC dba Internet Brands. All rights reserved. Use of this site indicates your consent to the Terms of Use.