7

A friend's computer was recently infected with a virus.

I hope the virus has been removed successfully. But, it appears that the virus set the "Hidden" flag on most directories and files on the system.

What's the most convenient way to clear this flag from selected directories and their contents?

2 Answers 2

9

You are looking for the "attrib" command. Type attrib /? at a command prompt.

An example would be attrib -h *.* to remove the hidden attribute from all files in the directory, or attrib -h *.* /s to include subdirectories. Add the /d switch to reset the directories too.

3
  • Anyone know how to make the * show? It seems only to happen when you do STAR.STAR, not just one star.
    – KCotreau
    Jun 9, 2011 at 23:08
  • Thanks for the answer! Hope you don't mind; I have proposed an edit to escape the asterisks. You can do that with backslashes, or by enclosing text with backquotes (which makes give it a style for code).
    – erickson
    Jun 9, 2011 at 23:22
  • You can also do this with -r (read only) -a (archive) -s (system) e.g. C:\Windows\System32\attrib.exe -r ..*.* /s /d see technet.microsoft.com/en-us/library/bb490868.aspx Dec 6, 2013 at 1:13
3

Download and run unhide (http://download.bleepingcomputer.com/grinler/unhide.exe).

It is for use when viruses (particularly fake failing HDD alerts) hide your files as part of what it does.

Works a treat for the odd occasion when these things happen here.

You must log in to answer this question.

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