Running under Windows 7 Enterprise SP1 x64.

When I try to create a folder with a certain name (for reference, let's assume it's X:\MyFolder, I'm getting this:

enter image description here

The name I am using does not show as a folder in Explorer, Total Commander or Far.

The name consists of Latin characters and an underscore, <20 characters long, being created under a drive's root (so no long names issue).

Any other folder name works fine.

I tried restarting - it did not help.

I tried a check disk - it did not find any errors.

  1. What could be preventing me from creating a folder with this name?

  2. Is there any other cleanup I can do on my file system, to get rid of this ghost somehow?

For those wondering, this is not a random name, it was destination path for Copy-Item command in Powershell, it failed to create this folder for some reason, now it keeps haunting me. :) The issue has been happening ever since, and only for this specific folder name, at this specific path.

  • Could you post the PowerShell code for us to have a look at it? – Darius Jan 6 '14 at 21:17
  • @Darius: I don't have this code anymore. But the statement that caused this behavior was trying to copy into a folder which did not exist. I forgot about a -Force statement, then I found that -Force does not work for files, only for folders, so I went with a different approach. I did not use source control, unfortunately. And I am not even sure if the issue is Powershell related - I cannot reproduce it. :) – Neolisk Jan 6 '14 at 21:23
  • So the earlier part of the PowerShell code was supposed to create a folder and then copy some "stuff" into it? – Darius Jan 6 '14 at 21:28
  • @AxelKemper: You are right. Time to end my working day and get some sleep I guess. I deleted a file with the same name (not sure how it got there though), now it's fine. Please post as an answer to be accepted. – Neolisk Jan 6 '14 at 21:30
  • @Darius: Correct. And somehow instead of copying stuff into a folder, it created a file with this folder's name (and no extension). See Axel's comment. – Neolisk Jan 6 '14 at 21:31

As said in the message text: This error message comes up, if a file (!) of the same name exists already. Windows does not allow a file and a folder to share the same name.

  • Nor does any OS or filesystem that I know of. – user1686 Jan 6 '14 at 22:40
  • 1
    Yes, but systems like Google Drive at least allow multiple files to have the same name. The timestamp is taken as distinction. – Axel Kemper Jan 6 '14 at 23:07
  • Now there's a radical idea: actually read what the error message says :) – dangph Jan 7 '14 at 0:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.