We help IT Professionals succeed at work.
Get Started

Batch to delete IE History folders - files in other user profile

Last Modified: 2012-05-11
I have classrooms computers require maintenance and manages,
when logged into (as) admin profile, need to run a batch file (below) to delete/remove history FROM other user profile,

Question., what's the correct input to execute that?



@echo off

REM Clears Temporary Internet Files
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 8

REM Clears Cookies
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 2

REM Clears History
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 1

REM Clears Form Data
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 16

REM Clears Passwords
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 32

REM Clears Delete All
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 255

REM Delete All - "Also delete files and settings stored by add-ons"
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 4351

echo y | chkdsk /f /r
echo y | gpupdate /force
echo enter 'shutdown -a' to abort the shutdown
start "" shutdown -f -r -t 30
Watch Question
This problem has been solved!
Unlock 2 Answers and 10 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE