Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I found this on a Windows XP machine and as well as a Windows 7 machine. That is certain files in C drive (not anywhere else yet), are hidden, though their hidden attribute is false (or unchecked). Those files look pale like other hidden files when made visible (from folder options) and they get hidden when we set "do not show hidden files" in folder options.

Those files in my machine as I see are autoexec.bat and config.sys in C:. Is there a way to identify such files, say from some script, registry or from programming environment? Basically I was trying to get the count of non-hidden files in a directory, and my application fails when it attempts to get count of files in C:. What happens is that the application counts those two files (since its attribute is not hidden), but from a visual standpoint, they are pale/hidden normally.

My point is not about System Files which requires a special setting in folder options to be shown. Such files and folders do have hidden attribute checked (though the checkbox in their case is readonly). They are in most ways similar to normal hidden files/folders. My question is about files that appear hidden but without hidden attribute. To see what is that, see your C drive for the files I mentioned if they happen to be there..

share|improve this question
Are these perhaps system files? The attribute would be +S instead of +H. You can check from a command prompt window. – user3463 Jul 30 '12 at 2:46
No they are not system files.. I will update my question – nawfal Jul 30 '12 at 3:07
Interesting, havn't notice this phenomenon before. I tried several tests, and found (1) AUTOEXEC.BAT or CONFIG.SYS must be named in UPPERcase, or they will not looks like hidden file. (2) AUTOEXEC.BAT or CONFIG.SYS must be placed in root directory of any drive. If they're not in root directory, then they're not looks like hidden file. I guess explorer.exe internally treat these special files as system files. Explorer++ does not treat these two file as hidden/system file because they do not have +H or +S attributes. – LiuYan 刘研 Jul 30 '12 at 5:44
@LiuYan刘研 what is even more interesting is that when u select those two files, you see in the details panel that they do have hidden property. But if u see properties by pressing alt+enter, the hidden attribute is surprisingly not there!! And my code (C#.NET) detects them as not hidden in the end :X :) – nawfal Jul 30 '12 at 6:18
@LiuYan刘研 That UPPERcase thing is interesting. DO you have any idea why it is so? – nawfal Jul 30 '12 at 6:23

They are hidden because they are operation system files although they are not hidden in the attribute. Just uncheck the line in the picture that i have highlighted. And you will be able to see the system files.

share|improve this answer
sorry for being rude, but this isn't what I am talking about. I updated my question – nawfal Jul 30 '12 at 3:01
There is no way to hide any file without checking hidden in attribute. Unless it is a system file – Zack Titan Jul 30 '12 at 3:03
Titan, you dont get it. I do agree there is no way for us, end users. But these are not files I or you created. These files come with operating system, or from some heavy weight third party application. Something programmatically must have created them. FYI, system files do have their hidden attribute checked, in a readonly manner. Please read my question.. – nawfal Jul 30 '12 at 3:06
@nawfal I think this command will do it. "dir /as" type this in cmd, this command will show system files. /a switch is used to show attrib files where "s" stand for system file. And i don't have those files you mentioned above. – Zack Titan Jul 30 '12 at 3:18
Ok Titan, thanks for that much. Let me see and get back to you asap. Could you remove the pic, and texts that are not related to my problem. It makes no sense to be there.. – nawfal Jul 30 '12 at 3:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .