Solved

How to delete AppData\Local\Microsoft\Windows\INetCache\IE\ temp files during logoff

Posted on 2015-01-31
4
10,167 Views
Last Modified: 2015-02-09
Hi guys,

I'm trying to get the AppData\Local\Microsoft\Windows\INetCache\IE\ files and folders deleted when an user logoff as the files needs to be deleted afterwards. The user for example download a document from the internet using IE and edit it straight away using libre office, so the file needs to be deleted after the user logoff.

I've tried this as a test:

C:\Users\Administrator>del /q /s C:\Users\%USERNAME%\AppData\Local\Microsoft\Win
dows\INetCache\IE\*.*
Deleted file - C:\Users\administrator\AppData\Local\Microsoft\Windows\INetCache\IE\35LF6500\V5M53G7K.htm
Deleted file - C:\Users\administrator\AppData\Local\Microsoft\Windows\INetCache\IE\HTH6Y87B\snippet[1].htm
Deleted file - C:\Users\administrator\AppData\Local\Microsoft\Windows\INetCache\IE\HTH6Y87B\snippet[2].htm
C:\Users\administrator\AppData\Local\Microsoft\Windows\INetCache\IE\QR5EKELF\TestWordDoc.doc
Access is denied.
Deleted file - C:\Users\administrator\AppData\Local\Microsoft\Windows\INetCache\IE\QR5EKELF\url[2].htm

Open in new window


as you can see it deletes most of the files, but not the document that was downloaded from the internet. This won't work even elevating the cmd to administrator priviledges.

What other ways I could do to clear these files out? I'm looking for perhaps a more elegant solution like a VB script.

Thanks!
0
Comment
Question by:Alex
  • 2
4 Comments
 
LVL 23

Expert Comment

by:NVIT
ID: 40581460
Have you tried this to  delete the cache?
- Run it while user is logged on.
- Be sure to close IE before running it.
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 8

Open in new window

0
 
LVL 3

Expert Comment

by:Adam Lewis
ID: 40582325
Have You tried any of these In IE settings?
Tools > Internet Options > General > Browsing History > Delete Browsing History on exit
Tools > Internet Options > General > Settings... > Caches and Databases > Un-check 'Allow website Caches and databases'
Tools > Internet Options > Advanced > Empty Temporary Internet Files when browser is closed
0
 

Accepted Solution

by:
Alex earned 0 total points
ID: 40588829
I ended up creating my own solution by executing a batch script to delete all files. It needed to be a group policy to work for all users
0
 

Author Closing Comment

by:Alex
ID: 40597947
sorted the problem with a batch script
0

Featured Post

Integrate social media with email signatures

Is your company active on social media? Do you also use email signatures? Including social media icons in your email signature is a great way to get fans for free. Let all your email users know you’re on social media quickly and easily, in a single click.

Join & Write a Comment

New Windows 7 Installations take days for Windows-Updates to show up and install. This can easily be fixed. I have finally decided to write an article because this seems to get asked several times a day lately. This Article and the Links apply to…
A safe way to clean winsxs folder from your windows server 2008 R2 editions
This tutorial will walk an individual through the steps necessary to install and configure the Windows Server Backup Utility. Directly connect an external storage device such as a USB drive, or CD\DVD burner: If the device is a USB drive, ensure i…
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles to another domain controller. Log onto the new domain controller with a user account t…

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now