|
Answer» Hello, I'm building a quick batch file that loops through the directory tree inside a folder (Example "TEST") and on every file it traverses it applies the HIDDEN attribute via the attrib command. The code I'm using is as follows..... Code: [Select]for /r %f in (*) do attrib +H %f It traverses the dir tree just fine but returns a "Parameter format not correct -" error after certain files IE .docx or .txt. Yet doesn't return an error for .exe files but doesn't apply the hidden attribute to them either. It seemed to work earlier in the sense that it applied the attribute, but then it wouldn't remove them. So I manually removed the attributes on the file(s) and ran the line again double checking it's functionality when I ran into the above mentioned errors. Any and all help is greatly appreciated, if you have any questions of me don't HESITATE to ask. Also I'm running Win7 x64.Your command above will fail with long FILENAME ELEMENTS - spaces etc. Perhaps you also need to run with elevated permissions.
This MIGHT work for you:
Code: [Select]attrib +H *.* /s Thanks that worked great for changing the attributes to hidden! Now changing the plus to a minus should obviously remove the hidden attribute, but sadly it does not.It does. The likelihood is that you have made a typo or some other error.
Maybe not refreshing the page after changing them.
|