'English 'History Cleaner of RUN and Notification Area (Windows 7) '(c) Mikhail Zhilin (MS MVP Teams 2000..2011) '04 Feb 2011 ' 'Performs the cleaning of Notification Area Past Icons (Tray history) 'and RUN MRU (RUN history) keys in Windows-7. ' 'Based on MS KB article http://support.microsoft.com/kb/Q283084 '"How do I clear past items from the Customize Notifications dialog box in Windows XP?" 'and my script dated 19 Sept 2004 è 23 Sept 2008 ' 'Thanks to Kelly Theriot (MS MVP) and Doug Knox (MS MVP) for the ideas. Dim WSh Set WSh = WScript.CreateObject("WScript.Shell") Message = "This script has to close Windows Explorer" & vbCR Message = Message & "(your Desktop will be empty for a few seconds)." & vbCR Message = Message & "Explorer will be run again when this script finished." & vbCR Message = Message & "That makes no harm to your system."& vbCR & vbCR Message = Message & "This script deletes 2 Registry keys and changes another one," & vbCR Message = Message & "so some of the monitoring programs (say, Norton AV) warn about"& vbCR Message = Message & "the malicious script with 'RegDelete' activity."& vbCR Message = Message & "You have to authorize this script then, and run it again."& vbCR & vbCR Message = Message & "Continue?" X = MsgBox(Message, vbYesNo, "Windows-7: History Cleaner of RUN and Notification Area") If X = 6 Then pn="HKCU\Software\Classes\Local Settings\Software\Microsoft\Windows\CurrentVersion\" pr="HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\" On Error Resume Next For Each Process in GetObject("winmgmts:"). _ ExecQuery ("select * from Win32_Process where name='explorer.exe'") Process.terminate(0) Next WSh.RegDelete pn & "TrayNotify\PastIconsStream" WSh.RegDelete pn & "TrayNotify\IconStreams" WSh.RegDelete pr & "RunMRU\" WSh.RegWrite pr & "RunMRU\","","REG_SZ" Else MsgBox "No changes were made.", 4096, "End" End If Set WSh = nothing