Solution
Hi
Okay, I have found the following works, but it actually deletes the DRM folder, not the files in it. The difference to the path is 'ProgramData' doesn;t have a space between the 2 words when you check the properties of the DRM folder.
Can you make it delete just the files in the DRM folder knowing what this one below does?
@echo off
cls
del "C:\ProgramData\Microsoft\Windows/DRM\*.*" /Q /F /S
rd "C:\ProgramData\Microsoft\windows/DRM" /S /Q
ping localhost -n 5 > nul
Pause
Okay, I have found the following works, but it actually deletes the DRM folder, not the files in it. The difference to the path is 'ProgramData' doesn;t have a space between the 2 words when you check the properties of the DRM folder.
Can you make it delete just the files in the DRM folder knowing what this one below does?
@echo off
cls
del "C:\ProgramData\Microsoft\Windows/DRM\*.*" /Q /F /S
rd "C:\ProgramData\Microsoft\windows/DRM" /S /Q
ping localhost -n 5 > nul
Pause
kaos
Senior Member
- Joined
- May 9, 2011
- Messages
- 1,742
hi
copy the text below into notepad and rename to .bat
@echo off
cls
del "c:/program Data/microsoft/windows/DRM" /F /Q /S
cls
echo Files have been deleted
ping localhost -n 5 > nul
exit
this will delete any files within the DRM folder based on the fact the path is c:/program Data/microsoft/windows/DRM
hope this helps
copy the text below into notepad and rename to .bat
@echo off
cls
del "c:/program Data/microsoft/windows/DRM" /F /Q /S
cls
echo Files have been deleted
ping localhost -n 5 > nul
exit
this will delete any files within the DRM folder based on the fact the path is c:/program Data/microsoft/windows/DRM
hope this helps
- Thread Author
- #3
Hi
Thank you for your reply.
When I run the bat file the files in the c:\program data\microsoft\windows\DRM are still there, it doesn't delete them?
I do have administrator rights on the PC so I am not sure what's up?
Any ideas?
Thanks again!
Derek
Thank you for your reply.
When I run the bat file the files in the c:\program data\microsoft\windows\DRM are still there, it doesn't delete them?
I do have administrator rights on the PC so I am not sure what's up?
Any ideas?
Thanks again!
Derek
kaos
Senior Member
- Joined
- May 9, 2011
- Messages
- 1,742
hi sorry for the delay
i just finished work
okidokies
to delete the FULL contents of the DRM folder, including all files, all folders please use the following, i only just clicked on what the DRM folder is haha...
slight amendments to the script
@echo off
cls
del "C:\ProgramData\Microsoft\DRM\*.*" /Q /F /S
rd "C:\ProgramData\Microsoft\DRM\" /S /Q
cls
echo Files have been deleted
ping localhost -n 3 > nul
exit
this will completly delete all files, folders and the DRM folder itself... if you dnt want the DRM folder removing completly let me no
i just finished work
okidokies
to delete the FULL contents of the DRM folder, including all files, all folders please use the following, i only just clicked on what the DRM folder is haha...
slight amendments to the script
@echo off
cls
del "C:\ProgramData\Microsoft\DRM\*.*" /Q /F /S
rd "C:\ProgramData\Microsoft\DRM\" /S /Q
cls
echo Files have been deleted
ping localhost -n 3 > nul
exit
this will completly delete all files, folders and the DRM folder itself... if you dnt want the DRM folder removing completly let me no
Last edited:
- Thread Author
- #5
Hi
Sorry to be a pain, but I ran the new bat file and the files in the DRM folder are still there, it hasn't deleted them or the folder.
I don't need the folder deleted, just all of the files in it.
I really appreciate yourt time and effort and hope you don't mind helping me.
Regards
Derek
Sorry to be a pain, but I ran the new bat file and the files in the DRM folder are still there, it hasn't deleted them or the folder.
I don't need the folder deleted, just all of the files in it.
I really appreciate yourt time and effort and hope you don't mind helping me.
Regards
Derek
kaos
Senior Member
- Joined
- May 9, 2011
- Messages
- 1,742
Just thought u said u had admin privledges in windows 7 there is uac or user acount control, if u ar an admin then thts. Okbut since uac.stops any deletion of system files it asks u if this a proper request
So
Use the same text as above save it as .bat
But right click and run as admin
Let me no if it works
So
Use the same text as above save it as .bat
But right click and run as admin
Let me no if it works
- Thread Author
- #10
I have right clicked and run the .bat as administrator and still no luck....the files are still in the DRM folder. I definatley have the admin rights on the PC so I am pretty sure that is not causing this to happen. As a matter of interest, are you running Win 7, and does it work on your PC? I have tried running it on a few other PC's too and it didn't work on them either. Any further help would be greatly appreciated. Derek
- Thread Author
- #12
Yes I have selected that option and can see the files in the folder as a result. It's strange how it's working on your PC but none of mine, maybe I'll run a few more tests outside of my network with the script and see what happens.
kaos
Senior Member
- Joined
- May 9, 2011
- Messages
- 1,742
plan b
try this
@echo off
cls
del "C:\Program Data\Microsoft\DRM\*.*" /Q /F /S
rd "C:\Program Data\Microsoft\DRM\" /S /Q
ping localhost -n 5 > nul
pause
this has a space between program and data
see what the box will say
because the cls has been removed " clear screen" it will display any error message
either
syntax error
unable to find file
access denied
etc etc etc
let me no wat it says
try this
@echo off
cls
del "C:\Program Data\Microsoft\DRM\*.*" /Q /F /S
rd "C:\Program Data\Microsoft\DRM\" /S /Q
ping localhost -n 5 > nul
pause
this has a space between program and data
see what the box will say
because the cls has been removed " clear screen" it will display any error message
either
syntax error
unable to find file
access denied
etc etc etc
let me no wat it says
- Thread Author
- #15
I also noticed the path in the last script was different to the path of the folder I am trying to have the files deleted from.
So I edited it to include the \Windows path that was missing in it, but still no luck. The message that was returned on running this version was 'The system cannot find the path specified'.
Here's what I have changed it to:
@echo off
cls
del "C:\Program Data\Microsoft\Windows\DRM\*.*" /Q /F /S
rd "C:\Program Data\Microsoft\Windows\DRM\" /S /Q
ping localhost -n 5 > nul
pause
So I edited it to include the \Windows path that was missing in it, but still no luck. The message that was returned on running this version was 'The system cannot find the path specified'.
Here's what I have changed it to:
@echo off
cls
del "C:\Program Data\Microsoft\Windows\DRM\*.*" /Q /F /S
rd "C:\Program Data\Microsoft\Windows\DRM\" /S /Q
ping localhost -n 5 > nul
pause
kaos
Senior Member
- Joined
- May 9, 2011
- Messages
- 1,742
@echo off
cls
del "C:\Program Data\Microsoft\Windows/DRM\*.*" /Q /F /S
rd "C:\Program Data\Microsoft\windows/DRM" /S /Q
ping localhost -n 5 > nul
Pause
You might have to goto the files through c: to get the path then tight click a file with the drm folder click.properties and that will give u the exact path
Try the above one on this post . I have taken out a / after the drm
And changed it to the path u said it might be
The *.* deletes any file within a folder. So e.g .Txt . Jpg .
Doc etc etc
We will do it run make sure you right click.and run as admin
cls
del "C:\Program Data\Microsoft\Windows/DRM\*.*" /Q /F /S
rd "C:\Program Data\Microsoft\windows/DRM" /S /Q
ping localhost -n 5 > nul
Pause
You might have to goto the files through c: to get the path then tight click a file with the drm folder click.properties and that will give u the exact path
Try the above one on this post . I have taken out a / after the drm
And changed it to the path u said it might be
The *.* deletes any file within a folder. So e.g .Txt . Jpg .
Doc etc etc
We will do it run make sure you right click.and run as admin
- Thread Author
- #17
Hi
Okay, I have found the following works, but it actually deletes the DRM folder, not the files in it. The difference to the path is 'ProgramData' doesn;t have a space between the 2 words when you check the properties of the DRM folder.
Can you make it delete just the files in the DRM folder knowing what this one below does?
@echo off
cls
del "C:\ProgramData\Microsoft\Windows/DRM\*.*" /Q /F /S
rd "C:\ProgramData\Microsoft\windows/DRM" /S /Q
ping localhost -n 5 > nul
Pause
Okay, I have found the following works, but it actually deletes the DRM folder, not the files in it. The difference to the path is 'ProgramData' doesn;t have a space between the 2 words when you check the properties of the DRM folder.
Can you make it delete just the files in the DRM folder knowing what this one below does?
@echo off
cls
del "C:\ProgramData\Microsoft\Windows/DRM\*.*" /Q /F /S
rd "C:\ProgramData\Microsoft\windows/DRM" /S /Q
ping localhost -n 5 > nul
Pause
kaos
Senior Member
- Joined
- May 9, 2011
- Messages
- 1,742
@echo off
cls
del "C:\ProgramData\Microsoft\Windows/DRM\*.*" /Q /F /S
rd "C:\ProgramData\Microsoft\windows/DRM" /S /Q <-------------------------------- this has been removed
ping localhost -n 5 > nul
Pause
__________________________________________________________
@echo off
cls
del "C:\ProgramData\Microsoft\Windows/DRM\*.*" /Q /F /S
ping localhost -n 5 > nul
Pause
^^^^^^^^^^^^^^^USE THIS ONE ^^^^^^^^^^^^^^^^^^
As you can see the file path has not changed in any way shape or form just one line removed.... the RD command is remove directory
ive still kept the command to keep the box open to show if ther are any errors,
if this works succesfully
then we can add a couple of more to make it a little more clearer

cls
del "C:\ProgramData\Microsoft\Windows/DRM\*.*" /Q /F /S
rd "C:\ProgramData\Microsoft\windows/DRM" /S /Q <-------------------------------- this has been removed
ping localhost -n 5 > nul
Pause
__________________________________________________________
@echo off
cls
del "C:\ProgramData\Microsoft\Windows/DRM\*.*" /Q /F /S
ping localhost -n 5 > nul
Pause
^^^^^^^^^^^^^^^USE THIS ONE ^^^^^^^^^^^^^^^^^^
As you can see the file path has not changed in any way shape or form just one line removed.... the RD command is remove directory
ive still kept the command to keep the box open to show if ther are any errors,
if this works succesfully
then we can add a couple of more to make it a little more clearer
Similar threads
- Article
- Replies
- 0
- Views
- 380
- Article
- Replies
- 0
- Views
- 281
- Article
- Replies
- 0
- Views
- 364
- Replies
- 0
- Views
- 1K
- Article
- Replies
- 0
- Views
- 1K