12

I'm unable to create an account named 'con' in Windows 7. I can create the account but each time I login, I see a notification that I'm working under a temporary profile and my files are wiped off after logging off. Any Advice/Suggestions on How to Fix?

This post gave me a hint but is not focused on user accounts but files and folders.

6

4 Answers 4

18

CON is a reserved word for Windows as it's the name of a device (console). Use something else.

8
  • 3
    Did you read the linked article?
    – Karan
    May 17, 2015 at 6:48
  • 15
    It's obvious really. Whether you attempt to create a folder named CON directly or try and trick Windows into creating one by using it as the user name, the problem remains the same.
    – Karan
    May 17, 2015 at 7:11
  • 4
    You could create a user with some alternate name, like Con01, then rename it to Con. The home folder doesn't typically move, so it should stick (e.g. it will display on the Welcome Screen as Con, but actually be housed in C:\Users\Con01). Still, I'd probably avoid trying to trick out Windows that way. The same rules also apply to COM1-4 and other reserved "device names."
    – phyrfox
    May 18, 2015 at 1:03
  • 1
    @phyrfox: Yes, the OP has apparently used that trick already if you read his answer. I would not recommend it but it's not my PC, so...
    – Karan
    May 18, 2015 at 1:05
  • 1
    @Karan it's not obvious to the OP or they wouldn't ask for clarification.
    – user64742
    Nov 4, 2018 at 0:54
15

Here's the answer to my own question. 'con' is a reserved keyword under Windows. So, when I try to create an account named con, the respective document directories fail to be created and hence when I login, all my data is stored in temp, which is wiped on logging out.

To fix this, I deleted the current account named 'con' and created an account named 'con0'. This successfully made an account named con0 with its respective document directories as con0. Then I changed the Account Name to 'con' which made windows to associate the 'con0' user folder to con User Account.

3
  • 6
    Ingenious. A little risky, perhaps - you might run into other problems later on, for the same reason - but ingenious. :-) May 17, 2015 at 7:13
  • 7
    Past experience just shows that using reserved words can have bad consequences. You will find out over time where the issues lie. Either take the advice or not as you choose. May 17, 2015 at 18:28
  • 6
    for example: any program that may create a folder or file (for settings, for example) named with your username will break. I don't know of any program like this (usually they instead store it underneath your home dir), but they could exist. May 18, 2015 at 11:57
5

When you create a user, Windows also creates a home folder for that user. Traditionally that home folder is named same as the user. So the process of creating the CON user expected to fail when creating their home folder because that name is not allowed in the file system.

Also note, that Windows' filesystem is case insensitive, so "con" and "Con" have the same issue.

I am not sure if you can create another user name and then rename the user, because there are potentially other places that will conflict with the name. The general advice is to stay away from the reserved words - the benefit is most likely not worth the fight.

3
  • 1
    The file system is actually case insensitive, with certain caveats.
    – Karan
    May 17, 2015 at 20:38
  • Thanks for the edits. Never again I will answer on the phone - screen too little to notice problems. I have also missed Sharad's self-answer there. May 18, 2015 at 0:04
  • There have been known security exploits taking advantage of such irregularities in the past, so the OS probably will go to great lengths to keep you from using these names. May 18, 2015 at 0:06
0

This has been answered, but yes it is a reserved device. When people were weaning themselves off CP/M and picking up DOS, most manuals described creating a file in this way... (close to the front, too).

copy con file.txt
...
...
^Z

(Some people are still doing this, it is like a VMS CREATE).

So that this will work, CON is reserved.

Others are COM1 COM2 COM3 COM4 PRN AUX LPT1

There are numerous KB articles and TechNet information pages concerning this, so it is odd that the question would come here.

2
  • I can't think of a better way in DOS 1.0, unless you wanted to use EDLIN (and who ever wanted to use EDLIN?)
    – hobbs
    May 18, 2015 at 4:47
  • 1
    Well not me, but I thought debug was cool and I missed it when it left. But I remember how great it was to have a ring bound manual come with the OS.
    – mckenzm
    May 18, 2015 at 6:59

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.