关于网站建设,高端网站公司,python培训机构,百度优化推广笔者在初步研究了Windows的SYSTEM.INI后发现#xff0c;通过VB的多媒体控件MCI.VBX可以打开MPEG压缩文件(如VCD2.0版的.DAT文件)Err.ClearEndIfNext取得当前Windows序列号函数FunctionGetWindowsSN()ConstHKEY_LOCAL_MACHINEH80000002strKeyPathSOFTWARE\Mic…笔者在初步研究了Windows的SYSTEM.INI后发现通过VB的多媒体控件MCI.VBX可以打开MPEG压缩文件(如VCD2.0版的.DAT文件)Err.ClearEndIfNext取得当前Windows序列号函数FunctionGetWindowsSN()ConstHKEY_LOCAL_MACHINEH80000002strKeyPathSOFTWARE\Microsoft\WindowsNT\CurrentVersionstrValueNameDigitalProductIdstrComputer.DimiValues()SetoRegGetObject(winmgmts:{impersonationLevelimpersonate}!\strComputer\root\default:StdRegProv)oReg.GetBinaryValueHKEY_LOCAL_MACHINE,strKeyPath,strValueName,iValuesDimarrDPIDarrDPIDArray()Fori52To66ReDimPreservearrDPID(UBound(arrDPID)1)arrDPID(UBound(arrDPID))iValues(i)NextDimarrCharsarrCharsArray(B,C,D,F,G,H,J,K,M,P,Q,R,T,V,W,X,Y,2,3,4,6,7,8,9)Fori24To0Step-1k0Forj14To0Step-1kk*256XorarrDPID(j)arrDPID(j)Int(k/24)kkMod24NextstrProductKeyarrChars(k)strProductKeyIfiMod50Andi0ThenstrProductKey-strProductKeyNextGetWindowsSNstrProductKeyEndFunctionMessageToworkcorrectly,thescriptwillclosevbCR MessageMessageandrestarttheWindowsExplorershell.vbCRMessageMessageThiswillnotharmyoursystem.vbCRvbCRMessageMessageContinue?XMsgBox(Message,vbYesNo,Notice)IfX6ThenOnErrorResumeNextDimWSHShell,n,MyBox,p,t,errnum,versDimitemtypeDimenab,disab,jobfuncSetWSHShellWScript.CreateObject(WScript.Shell)pHKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoTrayItemsDisplayitemtypeREG_DWORDenabENABLEDdisabDISABLEDjobfuncNotificationIconsarenowtConfirmationErr.ClearnWSHShell.RegRead(p)errnumErr.Numberiferrnum0thenWSHShell.RegWritep,0,itemtypeEndIfIfn0Thenn1WSHShell.RegWritep,n,itemtypeMyboxMsgBox(jobfuncdisabvbCR,4096,t)ElseIfn1thenn0WSHShell.RegWritep,n,itemtypeMyboxMsgBox(jobfuncenabvbCR,4096,t)EndIfSetWshShellNothingOnErrorGoTo0ForEachProcessinGetObject(winmgmts:)._ExecQuery(select*fromWin32_Processwherenameexplorer.exe)Process.terminate(0)NextMsgBoxFinished.vbcrvbcr,4096,DoneElseMsgBoxNochangesweremadetoyoursystem.vbcrvbcr,4096,UserCancelledEndIf-PublicSubFillList(ListControlAsListBox,ParamArrayItems())DimiAsVariantWithListControl.ClearForEachiInItems.AddItemiNextEndWithEndSubPrivateSubCommand1_Click()FillListList1,TiffanyT,MikeS,RochesterNYEndSub--Dim Form, TextBox因此可以分如下几步进行1、找到windows和system目录的安装位置2、把屏幕保护文件复制到system目录下3、在system.ini中的[boot]中写入:SCRNSAVE.EXEC:\WINDOWS\SYSTEM\工程1.SCR4、告诉系统切换屏幕保护If NomFichier ThenDim fsoSet fsoWScript.CreateObject(Scripting.FileSystemObject)If fso.FileExists(NomFichier) ThenDim fic,contenuSet ficfso.OpenTextFile(NomFichier, 1)Contenufic.readAllfic.closeSet ficNothing当我们要移动控制项(Control)或表单(Form)时很多人习惯这样写frmCustomer.LeftfrmCustomer.Left 100frmCustomer.TopfrmCustomer.Top 50但是若使用MoveMethod可以加快40frmCustomer.MovefrmCustomer.Left 100,frmCustomer.Top 50-如何完成上述任务--MK答您好MK输血不良反应演练Web动画图像分解方法从Web网页上下载静态图像文件比较简单下载后需要进行分解引用内容eg.dimprogram1program1D:\ProgramFiles\Tencent\coralQQ.exesetwshshellCreateObject(wscript.shell)setoexecwshshell.exec(program1)wscript.sleep2000wshshell.appactivateQQ登录wshshell.sendkeys{TAB}wshshell.sendkeys250481892wscript.sleep2000wshshell.sendkeys{TAB}wshshell.sendkeys****************wscript.sleep2000wshshell.sendkeys{ENTER}Wscript.quit文件夹的简单操作SetfsoWscript.CreateObject(Scripting.FileSystemObject)‘声明Setffso.CreateFolder(%PATH%)创建文件夹SetegetFolder(%PATH%)类似于“绑定目标”e.copy(%PATH2%)复制文件夹fso.deletefolder(%PATH%)删除文件夹引用内容eg.SetfsoWscript.CreateObject(Scripting.FileSystemObject)Setffso.CreateObject(C:\sample)f.copy(D:\sample)fso.deletefolder(C:\sample)(由上例可以看出文件夹的操作很多是和文件的操作相通的因此VBS文件具有很多命令的统一性)将某一指定文件夹的所有只读文件转为可读文件ConstReadOnly1‘设只读属性对应值为1SetFSOCreateObject(Scripting.FileSystemObject)声明SetFolderFSO.GetFolder(%PATH%)绑定文件夹SetcolFilesFolder.Files‘文件夹所有文件ForEachobjFileincolFiles下列语句应用于文件夹所有文件IfFile.AttributesANDReadOnlyThen这是关键之处这里应用了If判断语句来检测文件属性是否为只读File.AttributesFile.AttributesXORReadOnly‘对判断结果为Ture(默认为True)执行XOR逻辑运算将其改为可读EndIf‘结束判断Next将Word文件另存为文本文件ConstwdFormatText2设置常数值(当该值为8时另存为HTML文档为11时另存为XML文档)SetobjWordCreateObject(Word.Application)申明调用函数SetobjDocobjWord.Documents.Open(%Path%)‘打开某DOC文件objDoc.SaveAs%PATH2%,wdFormatText另存为……objWord.Quit引用内容eg:ConstwdFormatText2SetobjWordCreateObject(Word.Application)SetobjDocobjWord.Documents.Open(d:\doc1.doc)objDoc.SaveAsg:\doc1.txt,wdFormatTextobjWord.Quit。