如何重建图标缓存
如何重建图标缓存[ 本帖最后由 jiataifeng 于 2008-5-16 20:12 编辑 ] 是这样的,我用auto删除了桌面快捷方式的小箭头。可是需要重启才能生效。
有没有像超级兔子的那样,重建一下图标缓存,立即生效而不用重启电脑的办法呢? $size = DllCall("User32.dll","int","GetSystemMetrics","int",11)
RegWrite("HKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics", "Shell Icon Size", "REG_SZ", $size-1)
DllCall("user32.dll", "Int", "SendMessage", "hwnd", 0xFFFF, "int", 0x001A, "int", 0, "int", 0)
RegWrite("HKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics", "Shell Icon Size", "REG_SZ", $size)
DllCall("user32.dll", "Int", "SendMessage", "hwnd", 0xFFFF, "int", 0x001A, "int", 0, "int", 0) 牛人!
在下试试,谢谢了! 很好!两种方法都测试了。都可以。3楼的处理过程中任务栏会消失。霸王硬上攻啊。
4楼的更好。只有一些闪动。不错。
4#PERFECT!
RegDelete("HKEY_CLASSES_ROOT\lnkfile","IsShortcut")
RegDelete("HKEY_ CLASSES_ROOT\piffile","IsShortcut")
Do
ProcessClose("explorer.exe")
Until Not ProcessExists("explorer.exe")
Run("gpupdate /force","",@SW_HIDE)
#CS
;重新恢复小箭头
RegWrite("HKEY_CLASSES_ROOT\lnkfile","IsShortcut","REG_SZ","")
RegWrite("HKEY_CLASSES_ROOT\piffile","IsShortcut","REG_SZ","")
$size = DllCall("User32.dll","int","GetSystemMetrics","int",11)
RegWrite("HKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics", "Shell Icon Size", "REG_SZ", $size-1)
DllCall("user32.dll", "Int", "SendMessage", "hwnd", 0xFFFF, "int", 0x001A, "int", 0, "int", 0)
RegWrite("HKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics", "Shell Icon Size", "REG_SZ", $size)
DllCall("user32.dll", "Int", "SendMessage", "hwnd", 0xFFFF, "int", 0x001A, "int", 0, "int", 0)
#CE
[ 本帖最后由 jiataifeng 于 2008-5-16 20:11 编辑 ] 强悍呀,牛人,又学习了一招。 怎么我发出的代码都是乱做一团啊! 呵呵,又学到一招了 为什么运行时提示说使用了数组。。而运行 不成呢? win10三楼好用啊,四楼我测试无效。。
页:
[1]