| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 11011 人关注过本帖, 1 人收藏
标题:VB语法着色器
只看楼主 加入收藏
糖不苦
Rank: 1
等 级:新手上路
帖 子:2
专家分:0
注 册:2008-7-19
收藏
得分:0 
支持
2008-07-19 21:53
cbean
Rank: 1
等 级:新手上路
帖 子:44
专家分:0
注 册:2008-7-11
收藏
得分:0 
我的怎么没效果??
2008-07-19 23:59
茴憶
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2008-7-20
收藏
得分:0 
求助
楼主你好能帮看看这幅图的字是写上去的谢谢。
2008-07-20 15:41
永夜的极光
Rank: 6Rank: 6
等 级:贵宾
威 望:27
帖 子:2721
专家分:1
注 册:2007-10-9
收藏
得分:0 
[bo][un]茴憶[/un] 在 2008-7-20 15:41 的发言:[/bo]

楼主你好能帮看看这幅图https://hi.bccn.net/space.php?uid=271441&do=album&id=79的字是写上去的谢谢。

在左侧的工具栏,选择一个Label控件,在窗体上用鼠标拉出你需要的大小,然后更改其Caption属性
建议你找本VB入门书看看

从BFS(Breadth First Study)到DFS(Depth First Study)
2008-07-20 22:16
hoegs
Rank: 1
等 级:新手上路
帖 子:8
专家分:0
注 册:2008-1-10
收藏
得分:0 
给楼主的感谢信
楼主你真是太强悍了,我对您的仰慕就如滔滔江水一发不可收拾
2008-07-30 09:12
风吹过b
Rank: 20Rank: 20Rank: 20Rank: 20Rank: 20
等 级:贵宾
威 望:364
帖 子:4947
专家分:30084
注 册:2008-10-15
收藏
得分:0 
没下下来看。
看效果是不错。
图片附件: 游客没有浏览图片的权限,请 登录注册


我这个是 RTF 格式着色,核心部分也是语法解析,但也老解析错误。图中就有一个错误。
这是我着色核心函数,5个月前写的,没整理。

Public Function 彩色化(cs As String) As String

Dim i As Long, j As String
Dim js() As String
j = cs & vbCrLf
j = Replace(j, "\", "\\")           '单\换成双\\
js = Split(cs, vbCrLf)

If UBound(js) > 1000 Then
    If MsgBox("脚本非常长,进行命令标记需要很长的时间,是否继续?", vbInformation + vbOKCancel + vbDefaultButton2, 标题) = vbCancel Then
        彩色化 = cs
        Exit Function
    End If
End If

For i = 0 To UBound(js)
    If Left(Trim(js(i)), 1) = ";" Then
        j = Replace(j, js(i), "\cf1" & js(i) & "\cf0")
    'ElseIf Left(Trim(js(i)), 1) = "#" Then
    '    j = Replace(j, js(i), "\cf2" & js(i) & "\cf0")
    ElseIf Left(Trim(js(i)), 2) = "[~" Then
        j = Replace(j, Mid(js(i), 2, Len(js(i)) - 2), "\cf4" & Mid(js(i), 2, Len(js(i)) - 2) & "\cf0")
    End If
Next i

'j = Replace(j, js(i), "\cf1" & js(i) & "\cf0")
For i = 0 To UBound(命令)
    With 命令(i)
    If Len(.命令) > 2 Then
    Select Case Left(.命令, 1)
        Case "#"
            j = Replace(j, .命令, "\cf2 " & .命令 & "\cf0 ")
        Case "\"

        Case "."

        Case Else
            If InStr(1, j, .命令 & " ") > 0 Then
                j = Replace(j, .命令 & " ", "\cf3 " & .命令 & " \cf0 ", , , vbTextCompare)
            End If
    End Select
    End If
    End With
Next i

    Call 取标记(txtbox.Text)

On Error GoTo err1:
For i = 0 To UBound(标记)
    With 标记(i)
            j = Replace(j, "[@" & .标记名称 & "]", "[\cf4 @" & .标记名称 & "\cf0 ]")
            j = Replace(j, " @" & .标记名称 & " ", " \cf4 @" & .标记名称 & " \cf0 ")
            j = Replace(j, "@" & .标记名称 & ">", "\cf4 @" & .标记名称 & "\cf0 >")
    End With
Next i

err2:
On Error GoTo 0
    j = Replace(j, vbCrLf, vbCrLf & "\par ")        '换回车符
    j = Replace(j, "\par \cf", "\par\cf")         '换掉标记中间的空格
   
    j = "\viewkind4\uc1\pard\lang2052\f0\fs21" & j     '加头,倒次序加,显示头,颜色表,RTF头
    j = "{\colortbl ;\red0\green128\blue64;\red128\green0\blue64;\red0\green0\blue128;\red128\green0\blue255;}" & vbCrLf & j
    j = "{\rtf1\ansi\ansicpg936\deff0\deflang1033\deflangfe2052{\fonttbl{\f0\fnil\fcharset134 \'cb\'ce\'cc\'e5;}}" & vbCrLf & j
    j = j & "}"                                     '加结尾
   
    彩色化 = j
    Exit Function
err1:
    GoTo err2:
End Function
2008-10-16 01:13
qyb966
Rank: 1
等 级:新手上路
帖 子:26
专家分:0
注 册:2009-7-28
收藏
得分:0 
不错不错  支持版主!
2009-07-28 15:19
不说也罢
Rank: 13Rank: 13Rank: 13Rank: 13
等 级:贵宾
威 望:39
帖 子:1481
专家分:4989
注 册:2007-10-7
收藏
得分:0 
这个贴子我也顶一下。

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



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.049018 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved