Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > VB Script

Vista - Create vbscript to empty secure temp folder when exiting Outlook.

Reply
 
Old 12-10-2008   #1 (permalink)
PaulyBalls


 
 

Create vbscript to empty secure temp folder when exiting Outlook.

Hi all:

I got the code below from another site to clear the Outlook secure
temp folder but I don't know how to use it. Can I configure this to
run when exiting Outlook? Can someone walk me through it step by
step? I'm not familiar at all with scripting. I'm using Outlook
2007.

Thanks,
Paul

Set oWSH = CreateObject("WScript.Shell")
Set oFSO = CreateObject("Scripting.FileSystemObject")

For Each sKey In Array("11.0", "12.0")
sOutSecTmp = Empty
On Error Resume Next
sOutSecTmp = oWSH.RegRead("HKCU\Software\Microsoft\Office\" _
& sKey & "\Outlook\Security\OutlookSecureTempFolder")
If Len(sOutSecTmp) > 3 Then
oFSO.DeleteFile oFSO.BuildPath(sOutSecTmp, "*.*"), True
End If
Next

My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
Windows Vista strange settings on temp folder AppData\Local\Temp\1 Vista security
Remove empty folders in C:\Windows\Temp ?? Vista General
Outlook secure temp folder VB Script
Unable to empty Deleted Items Folder in Vista Office Outlook 32 bit Microsoft Office
empty temp folder Vista General


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46