how to use remove-item cmdlets to delete hidden folder files ? - TechRepublic
Question
August 9, 2011 at 04:04 AM
tathedketan

how to use remove-item cmdlets to delete hidden folder files ?

by tathedketan . Updated 14 years, 10 months ago

I want to delete text files from ‘temp’ folder who have hidden sub folder ‘temp2’. This sub folder also contain text files which I need to delete at the same time. I tried the following command but it’s not working.

Remove-Item “C:\Documents and Settings\Administrator\Desktop\temp\*” -force -recurse -include *.txt

It is deleted only text file of ‘temp’ folder. Kindly help me to sort out this issue.

Thanks & Regards

Ketan

This discussion is locked

All Comments