Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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?

share|improve this question

2 Answers 2

up vote 7 down vote accepted

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.

share|improve this answer
    
Anyone know how to make the * show? It seems only to happen when you do STAR.STAR, not just one star. –  KCotreau Jun 9 '11 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 '11 at 23:22
    
Thank you erickson. Looks great now. –  KCotreau Jun 10 '11 at 0:16
    
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 –  Tod Thomson Dec 6 '13 at 1:13

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.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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