Sign in to follow this  
Followers 0
inuyasha

delete file hidden

7 posts in this topic

how do you delete file hidden ?

Share this post


Link to post
Share on other sites



I don't think hidden files delete any differently then other files.

FileDelete ( "path" )

Share this post


Link to post
Share on other sites

@inuyasha...If you are looking to delete only the hidden files then do this...

1. Use FileFindFirstFile & FileFindNextFile functions...to get all the names of the files in a certain folder.

2. Use FileGetAttrib to get only the files that have the "hidden" attribute.

3. Like Weaponx stated...then use FileDelete to delete only the hidden files.

I dont know why you would do this but please ignore this if this is not what u wanted todo.

Share this post


Link to post
Share on other sites

you can make use of Dos comment through AutoIt for example "run(@COMSPEC & " /c del /A:R /A:H $Filenamewithpath)"


------------------------------------------------------"You are never a loser,until you quit trying"------------------------------------------------------

Share this post


Link to post
Share on other sites

you can make use of Dos comment through AutoIt for example "run(@COMSPEC & " /c del /A:R /A:H $Filenamewithpath)"

Or you can use the native AutoIt command FileSetAttrib .

William

Share this post


Link to post
Share on other sites

To delete hidden or system files try this code:

if fileexists("C:\blah.exe") then
Filesetattrib("C:\blah.exe","-RASHOT)
FileDelete("C:\blah.exe")
Msgbox(64, "DONE", "DONE")
else
Msgbox(16, "ERROR", "FAILED")
endif

That should help... :unsure:

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0