The VBScript Network and Systems Administrator's Cafe

Jan 19 2009   4:14AM GMT

Windows Tip: Clearing Internet Explorer cached data from the command line



Posted by: Jerry Lees
Tags:
batch commands
batch files
command line
Internet Explorer
rundll.exe
tips and tricks
undocumented windows
windows secrets
windows tips

As a Network Administrator sometimes you need to clear the browsing history, cookies, or the like for a entire community of users. Sure, you could tell them how to do it thinking that you were being super smart by providing instructions for them. However, as you well know there will be some who will be unable to follow the directions and you will spend 3 times the amount of time it took you to write the directions and refine them to a point where any one could do it— or so you thought. All the while, thinking about the amount of time you will save by having the users do it.

Why not be really lazy!!!??!? And do it with a batch script? You could then put it in their login script and it would happen at their next logon, or every logon for that matter. Well, there’s an easy way to do this with windows’ built in functions– it’s just obscure enough to not be found anywhere you would normally look!

Yo can preform many of the things I mentioned (and more) with Microsoft’s RUNDLL.EXE file, plus you don’t have to write a line of VBScript to accomplish the task!

Here is a short list of some tasks you can preform on IE, along with the command to do it… give them a shot!

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

Cookies
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 2

History
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 1

Form Data
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 16

Passwords
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 32

Delete All
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 255

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

 These commands should work in Internet Explorer 7

 Comment on this Post

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to: