Announcement

Collapse
No announcement yet.

Creating an Appdata batch file windows 7

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Creating an Appdata batch file windows 7

    Hey all, I'm looking for a batch file that can delete a folder inside of the appdata roaming and local folders for every user on the local machine. Can anyone give me a hand? Thanks!

  • #2
    Re: Creating an Appdata batch file windows 7

    This will loop through all the user profiles on the computer, assuming C: is the system drive.
    Code:
    @echo off
    for /f %%a in ('dir c:\users /b') do (
      rd c:\users\%%a\AppData\Roaming\foldername /s /q
      )
    Change "foldername" to the folder you want to remove.
    Regards,
    Jeremy

    Network Consultant/Engineer
    Baltimore - Washington area and beyond
    www.gma-cpa.com

    Comment

    Working...
    X