' NAME: OpenOutlookAttachmentsFolder.vbs ' ' AUTHOR: Alan dot Kaplan at VA dot GOV ' DATE : 7/15/2010 ' ' COMMENT: Opens the Outlook Attachment folder for all MS OS, all versions of Office ' based on article here: http://www.groovypost.com/howto/microsoft/outlook/find-the-microsoft-outlook-temporary-olk-folder/ '========================================================================== Option Explicit dim wshShell: Set wshShell = WScript.CreateObject("WScript.Shell") Dim fso: set fso = CreateObject("Scripting.FileSystemObject") Dim sSubKeyName,sValueName Dim strAppPath, tArray, strVer, strFolder Dim quote: quote=chr(34) sSubKeyName="HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\Outlook.exe\path" strAppPath = wshShell.RegRead (sSubKeyName) If Len(strAppPath) = 0 Then 'outlook not installed" WScript.Quit (1) End If tArray = Split (fso.GetFileVersion(strAppPath & "outlook.exe"),".") strVer = tArray(0) & "." & tArray(1) strFolder = wshShell.RegRead ("HKEY_CURRENT_USER\Software\Microsoft\Office\"& strVer &"\Outlook\Security\OutlookSecureTempFolder") wshShell.Run quote & strFolder & quote ,1,False