About Ed Hands

 I have been working in the IT field for over twenty years.  

In addition to spending time with my beautiful wife and two lovely daughters,  I enjoy practicing the guitar, Tae Kwon Do, reading, and grilling out  I am always trying to plan the perfect road-trip with my family.  Hopefully there will be coffee.

The purpose of this blog is to journal my experience in the IT field and hopefully provide a useful guide to those doing likewise.  And to journal my random musings on technology, computers, or whatever else strikes my fancy.  Adult ADD FTW!!!!  Ohhh...look...something shiny....

 

Google

Follow me!
Navigation
BlogTopSites
Technology Blogs
technology blogs
Web Directory
OnToplist is optimized by SEO
Add blog to our directory.
ping web site via FeedShark
Shameless Self-Promotion

 

 

Ads (Please help support this site. Thanks!)

Main | Western Digital TV Live Plus….$100 well spent! »
Friday
Jan202012

DOS and the Attrib Command

Today I was working on a problem that seemed to have no easy answer other than using a VB script of a batch file. Yet I found one in lowly DOS commands. 

The issue that I was having we as that I had a large number of directories that I need to change that attibutes on.  The folders all had the hidden and system attribute and I wanted to change it so that they could be seen.

I started working on a batch file to run the attrib -s -h on each folder but was having a probelm that, even though it seemed to process the command correctly, it failed to actually change the attibute.

Then as I was looking at the switches for the attrib command I found the /S /D switches that I never knew about.

So my long batch file that I was creating and testing for 90 minutes was simply replaced by this:

attrib -r -s /S /D

Voila!  Done.

...Just in time to go home for lunch!

PrintView Printer Friendly Version

EmailEmail Article to Friend

Reader Comments

There are no comments for this journal entry. To create a new comment, use the form below.

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
Post:
 
Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>