<br>
Private Sub REGXIOUF_Click()<br>
On Error Resume Next<br>
Dim ItemStr() As String<br>
Dim st As String<br>
Dim tia As Long<br>
Dim SubKey As String<br>
Dim sText As Variant<br>
Dim miaoshu(0 To 1000) As String<br>
sText = Array( _<br>
"允许Windows执行任何程序=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|RestricRun|0|1", "允许用户使用Windows任务管理器=1|Software\Microsoft\Windows\CurrentVersion\Policies\System|DisableTaskMgr|0|1", "允许用户更改密码=1|Software\Microsoft\Windows\CurrentVersion\Policies\System|DisableChangePassword|0|1", _<br>
"允许用户关闭计算机=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoClose|0|1", "允许用户使用控制面板=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoControlPanel|0|1", "允许使用右键菜单=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoViewContextMenu|0|1", _<br>
"允许IE显示(工具)中(INTERNET选项)=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoFolderOptions|0|1", "允许更改IE的连接设置=1|Software\Policies\Microsoft\Internet Explorer\Control Panel|Connection Settings|0|1", "允许使用系统中的热键=1|Software\Microsoft\Windows\CurrentVersion|NoWindows Keys|0|1", _<br>
"允许使用IE下载文件=1|Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\3|1803|0|1", "允许用户使用CMD=1|Software\Policies\Microsoft\Windows\System|DisableCMD|0|1", "允许用户锁定任务栏=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoSetTaskbar|0|1", _<br>
"允许修改显示属性=1|Software\Microsoft\Windows\CurrentVersion\Policies\System|NoDispCPL|0|1", "允许使用注册表编辑器=1|Software\Microsoft\Windows\CurrentVersion\Policies\System|DisableRegistryTools|0|1", "允许改变启动菜单=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoChangeStartMenu|0|1", _<br>
"允许使用(控制面版)中的(密码)图标设置功能=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoSecCPL|0|1", "允许修改(开始)菜单=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explore|NoChangeStartMenu|0|1", "允许查找功能=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoFind|0|1", _<br>
"允许使用(控制面板)=1|Software\Microsoft\ Windows\CurrentVersion\Policies\System|NoDispCPL|0|1", "允许(文件系统)菜单出现在系统属性中=1|Software\Microsoft\Windows\CurrentVersion\Policies\System|NoFileSysPage|0|1", "允许IE更改主页=1|Software\Policies\Microsoft\Internet Explorer\Control Panel|homepage|0|1", _<br>
"允许使用Regedit命令=1|Software\Microsoft\Windows\CurrentVersion\Policies\System|DisableRegistryTools|0|1", "允许进入DOS=1|Software\Microsoft\Windows\CurrentVersion\Policies\Win01dApp|NoRealMod|0|1", "禁用错误报告=2|SOFTWARE\Microsoft\PCHealth\ErrorReporting|DoReport|0|0", _<br>
"禁止Windows漫游气球提醒=2|software\Microsoft\Windows\CurrentVersion\Applets\Tour|RunCount|0|1", "禁止IE自动安装组件=2|SOFTWARE\Policies\Microsoft\Internet Explorer\Infodelivery\Restrictions|NoJITSetup|1|1", "禁止远程修改注册表=2|SYSTEM\CurrentControlSet\Control\SecurePipeServers\winreg|RemoteRegAccess|1|1", "禁止高亮显示新安装的程序(开始菜单)=1|Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced|Start_NotifyNewApps|0|1", "禁用磁盘空间不足警告=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoLowDiskSpaceChecks|1|1", _<br>
"禁止IE标题栏锁定(HUCK)=1|SOFTWARE\Microsoft\Internet Explorer\Main|Window Title||0", "禁止隐藏用户所有磁盘驱动器=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoDrives|0|1", "禁止光盘自动播放(建议)=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoDriveTypeAutoRun|255|1", "禁止桌面图标被隐藏=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoDesktop|0|1", "禁用防火墙提醒=2|SOFTWARE\Microsoft\Security Center|FirewallDisableNotify|1|1", "禁止系统崩溃时,显示蓝屏死机(BSOD)<建议>=2|SYSTEM\ControlCurrentSet\Control\CrashControl|AutoReboot|0|1", _<br>
"禁止屏幕保护使用密码=1|ControlPanel\desktop|ScreenSaveUsePassword|0|1", "禁止系统启动时弹出对话框(标题)=2|Software\Microsoft\Windows\CurrentVersion\Winlogon|LegalNoticeCaption||0", "禁止桌面清理向导=1|Software\Microsoft\Windows\CurrentVersion\Explorer\Desktop\CleanupWiz|NoRun|1|1", "禁用最近历史记录=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoRecentDocsHistory|1|1", "禁止窗体动画=1|Control Panel\Desktop\WindowMetrics|MinAnimate|0|0", "禁用系统还原=2|SOFTWARE\Microsoft\Windows NT\CurrentVersion\SystemRestore|DisableSR|1|1", _<br>
"禁止锁定桌面=1|Software\Microsoft\Windows\CurentVersion\Polioies\Explores|No Save Setting|0|1", "禁止启动时弹出错误信息=2|SYSTEM\CurrentControlSet\Control\Windows|NoPopUpsOnBoot|1|1", "禁用杀毒软件提醒=2|SOFTWARE\Microsoft\Security Center|AntiVirusDisableNotify|1|1", _<br>
"启用关机时清除分页文件=2|SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management|ClearPageFileAtShutdown|1|1", "启用(任务栏属性)功能=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoSetTaskBar|0|1", "启用关机清除临时文件=1|Software\Microsoft\Windows\CurrentVersion\Explorer|CleanShutdown|1|1", _<br>
"显示(网上邻居)=1|Software\Microsoft\ Windows\CurrentVersion\Policies\Explorer|NoNetHood|0|1", "显示菜单(运行)=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoRun|0|1", "显示文件扩展名=2|SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\Folder\HideFileExt|UncheckedValue|0|1", "显示所有文件和文件夹选项=2|SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\Folder\Hidden\SHOWALL|CheckedValue|1|1", "显示桌面图标=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoDeskTop|0|1", _<br>
"不显示系统登录入门欢迎屏幕=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoWelcomeScreen|0|1", "关机时删除虚拟内存=2|SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management|DisablePagingExecutive|1|1", "关闭(开始)菜单动画提示=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoStartMenuEjectPC|1|1", "关闭自动重启功能=2|SYSTEM\CurrentControlSet\Control\CrashControl|AutoReboot|0|1", "自动结束任务计划时不进行回应(建议)=1|Control Panel\Desktop|AutoEndTasks|1|0", "自动终止无响应程序=1|Control Panel\desktop|AutoEndTasks|1|0", _<br>
"不把删除文件放到回收站=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|NoRecycleFiles|1|1", "优化桌面进程=1|Software\Microsoft\Windows\CurrentVersion\Explorer|DesktopProcess|1|1", "优化操作系统开机速度(推荐)=2|SOFTWARE\Microsoft\Dfrg\BootOptimizeFunction|Enable|Y|0", _<br>
"加快开始菜单的显示=1|Control Panel\Desktop|MenuShowDelay|1|0", "加快程序运行速度=2|SYSTEM\CurrentControlSet\Control\FileSystem|ConfigFileAllocSize|500|1", "加快XP的开关机的等待时间=2|System\CurrentControlSet\Control|WaitToKillServiceTimeout|500|0", "减少开机滚动条滚动次数=2|SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management\PrefetchParameters|EnablePrefetcher|1|1", _<br>
"使用大系统缓存=2|SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management|LargeSystemCache|1|1", "空白IE浏览器首页=1|Software\Microsoft\Internet Explorer\Main|Start Page|about:blank|0", "用户名不出现在登录框中=2|Software\Microsoft\Windows\CurrentVersion\Winlogon|DontDisplayLastUserName|1|0", _<br>
"空白IE的搜索页=2|Software\Microsoft\Internet Explorer\Main|Default_Search_URL||0", "空白IE的默认页=2|Software\Microsoft\Internet Explorer\Main|Default_Page_URL||0", "退出清除历史列表=1|Software\Microsoft\Windows\CurrentVersion\Policies\Explorer|ClearRecentDocsOnExit|1|1", "不加载多余DLL文件<建议>=2|SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\AlwaysUnloadDLL||1|0", _<br>
"每次启动保持桌面设置不变=1|Software\Microsoft\Windows\CurrentVersion\ Polices\Explorer|NoSaveSettings|0|1", "删除WINXP默认共享=2|SYSTEM\CurrentControlSet\Services\lanmanserver\parameters|AutoShareServer|0|1", "删除WINXP默认共享2=2|SYSTEM\CurrentControlSet\Services\lanmanserver\parameters|AutoShareWks|0|1", "删除浏览器临时文件=2|Software\Microsoft\Windows\CurrentVersion\Internet Setting\Cache|Persistent|1|1")<br>
For tia = 0 To UBound(sText)<br>
miaoshu(tia) = sText(tia)<br>
Next tia<br>
SubKey = xioufu(miaoshu(RepairAndSetList.SelectedItem.Index - 1))<br>
ItemStr = Split(SubKey, "|")<br>
If ItemStr(4) = "0" Then<br>
CreateStringValue HKEY_CLASSES_ROOT + CLng(ItemStr(0)), ItemStr(1), ItemStr(2), ItemStr(3)<br>
Else<br>
CreateDwordValue HKEY_CLASSES_ROOT + CLng(ItemStr(0)), ItemStr(1), ItemStr(2), CLng(ItemStr(3))<br>
End If<br>
Call GetRepairandSet<br>
End Sub