Rebuild the two scripts cached by the icon-Bat command and vbs File

Source: Internet
Author: User

The first is to use the bat batch processing command, which can be executed normally.

Rem closes Windows shell program explorertaskkill/f/IM explorer.exe REM cleanup System Icon cache database attrib-H-S-R "% USERPROFILE % \ appdata \ Local \ iconcache. DB "del/F" % USERPROFILE % \ appdata \ Local \ iconcache. DB "attrib/S/D-H-S-R" % USERPROFILE % \ appdata \ Local \ Microsoft \ Windows \ Explorer \ * "del/F" % USERPROFILE % \ appdata \ local \ Microsoft \ Windows \ Explorer \ thumbcache_32.db "del/F" % USERPROFILE % \ appdata \ Local \ Microsoft \ Windows \ Explorer \ thumbcache_96.db "del/F" % USERPROFILE % \ appdata \ local \ Microsoft \ Windows \ Explorer \ thumbcache_102.db "del/F" % USERPROFILE % \ appdata \ Local \ Microsoft \ Windows \ Explorer \ thumbcache_256.db "del/F" % USERPROFILE % \ appdata \ local \ Microsoft \ Windows \ Explorer \ thumbcache_1024.db "del/F" % USERPROFILE % \ appdata \ Local \ Microsoft \ Windows \ Explorer \ thumbcache_idx.db "del/F" % USERPROFILE % \ appdata \ local \ Microsoft \ Windows \ Explorer \ thumbcache_sr.db "Echo y | Reg Delete" hkey_classes_root \ Local Settings \ Software \ Microsoft \ Windows \ CurrentVersion \ traynotify "/V iconstreamsecho y | Reg Delete "hkey_classes_root \ Local Settings \ Software \ Microsoft \ Windows \ CurrentVersion \ traynotify"/V pasticonsstreamrem restart Windows Shell assumerstart Explorer

The second is the vbs file, which prompts an error. If you want to know VB, correct it ....

On Error resume nextIf msgbox ("close all open Resource Manager windows and recreate the Icon cache. "_ & Vbcrlf &" continue? ", Vbyesno + vbquestion," ") = vbno thenwscript. quitend ifset FSO = Createobject ("scripting. fileSystemObject ") FSO. deletefile (FSO. getspecialfolder (0) & "\ shelliconcache") set FSO = nothingset pros = GetObject ("winmgmts :\\. \ Root \ cimv2 "). execquery ("select * From win32_process where name = 'cmder.exe '") for each pro in Prospro. the terminatenextset pros = nothingmsgbox operation has been completed. ", Vbinformation," prompt"

The error message is:

Now we know the cause of the above error. Thank you, tea_pig!

Modify the second sentence of the program to the following and add an underscore!

If msgbox ("close all open Resource Manager windows and recreate the Icon cache. "& Vbcrlf &" continue? ", Vbyesno + vbquestion," ") = vbno then

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.