分类 杂七杂八 下的文章

1.新建一个TXT文本文档

2.输入下面的代码段

@echo off
mode con cols=50 lines=30
color F0
title 恢复win7照片查看器

Rd "%WinDir%\system32\test_permissions" >NUL 2>NUL  
Md "%WinDir%\System32\test_permissions" 2>NUL||(Echo 请求获取管理员身份运行(请按回车键) &&Pause >nul&&echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs"
echo UAC.ShellExecute "%~s0", "", "", "runas", 1 >> "%temp%\getadmin.vbs"
"%temp%\getadmin.vbs"
exit /B)
Rd "%WinDir%\System32\test_permissions" 2>NUL

echo 添加.jpg格式
reg add "HKLM\SOFTWARE\Microsoft\Windows Photo Viewer\Capabilities\FileAssociations" /v ".jpg" /t REG_SZ /d PhotoViewer.FileAssoc.Tiff /f
echo 添加.jpeg格式
reg add "HKLM\SOFTWARE\Microsoft\Windows Photo Viewer\Capabilities\FileAssociations" /v ".jpeg" /t REG_SZ /d PhotoViewer.FileAssoc.Tiff /f
echo 添加.png格式
reg add "HKLM\SOFTWARE\Microsoft\Windows Photo Viewer\Capabilities\FileAssociations" /v ".png" /t REG_SZ /d PhotoViewer.FileAssoc.Tiff /f
echo 添加.gif格式
reg add "HKLM\SOFTWARE\Microsoft\Windows Photo Viewer\Capabilities\FileAssociations" /v ".gif" /t REG_SZ /d PhotoViewer.FileAssoc.Tiff /f
echo 添加.tif格式
reg add "HKLM\SOFTWARE\Microsoft\Windows Photo Viewer\Capabilities\FileAssociations" /v ".tif" /t REG_SZ /d PhotoViewer.FileAssoc.Tiff /f
echo 添加.bmp格式
reg add "HKLM\SOFTWARE\Microsoft\Windows Photo Viewer\Capabilities\FileAssociations" /v ".bmp" /t REG_SZ /d PhotoViewer.FileAssoc.Tiff /f
echo 添加.ico格式
reg add "HKLM\SOFTWARE\Microsoft\Windows Photo Viewer\Capabilities\FileAssociations" /v ".ico" /t REG_SZ /d PhotoViewer.FileAssoc.Tiff /f
echo 请在设置-^>应用-^>默认应用中将图片查看器的默认应用修改为Windows照片查看器
pause
:abcd
cls
echo 如果您还要继续添加图片格式,请在下方输入(如 .jpg)(请确保后缀名正确)。没有则关闭窗口。
set /p b=
set a=reg add "HKLM\SOFTWARE\Microsoft\Windows Photo Viewer\Capabilities\FileAssociations" /v "
set c=" /t REG_SZ /d PhotoViewer.FileAssoc.Tiff /f
set d=%a%%b%%c%
set e=添加
set f=格式
set g=%e%%b%%f%
echo %g%
%d%
echo 请在设置-^>应用-^>默认应用中将图片查看器的默认应用修改为Windows照片查看器
pause
goto abcd

3.然后把.txt改名为.bat

4.双击打开,然后一路按照引导走

解决方法

【控制面板】-【颜色管理】-【高级】-【设备配置文件】,【切换为agfa】即可。
原来显示内存不足的图片就能打开了,当然了对极少数图片可能还不行,但我还没遇见。