梦幻西游辅助脚本自动在哪下载

这三个文本框控件将分别用于填写邮件的收件人、主题和内容您应该看到当前目录下的所有文件和文件夹列表

sqlserver 生成脚本 DefaultVisible:控制自定义按钮是否可见,一般为“Yes”

OptionButton控件经常是作为控件数组存在的,要快速找到其中的哪一个被选中,可以使用下面的代码:

'假设控件数组包含3个OptionButton控件

intSelected=Option(0).Value*0-Option(1).Value*1-Option(2).Value*2

注意,因为第一个操作数总是0,所以上述代码可以精简如下:

intSelected=-Option(1).Value-Option(2).Value*2

->

Class clsGetProfile ' ル`トドキュメント Private rootDoc ' xmlファイル名とセクション名をセットする ' 引数: 「1」ファイル名 NOT NULL ' 氦胜 Public Sub setProfile(strFileName) Set data_xml=CreateObject("Microsoft.XMLDOM") data_xml.async=False data_xml.load(strFileName) Set rootDoc=data_xml.documentElement End Sub ' キ`のする蛉〉盲工 ' 引数: 「1」キ`名  NOT NULL ' 「2」セクション名 NOT NULL ' 亥`のする Public Function getItem(strSectionName, itemName) Set sectionNode=rootDoc.selectSingleNode(strSectionName) getItem=sectionNode.selectSingleNode(itemName).attributes(0).nodeValue End Function End Class ' 使用サンプル ' クラスインスタンスを生成する 'Dim config : Set config=New clsGetProfile ' 配置ファイル名とセクション名をセットする 'Call config.setProfile("Config.xml") ' き`のする颔播氓趣工 'WScript.Echo config.getItem("MessageDefine", "INFO.001") 'WScript.Echo config.getItem("MessageDefine", "INFO.003") 'WScript.Echo config.getItem("MessageDefine", "ERROR.009") 'WScript.Echo config.getItem("MessageDefine", "ERROR.012") Class clsGetProfile ' ル`トドキュメント Private rootDoc ' xmlファイル名とセクション名をセットする ' 引数: 「1」ファイル名 NOT NULL ' 氦胜 Public Sub setProfile(strFileName) Set data_xml=CreateObject("Microsoft.XMLDOM") data_xml.async=False data_xml.load(strFileName) Set rootDoc=data_xml.documentElement End Sub ' キ`のする蛉〉盲工 ' 引数: 「1」キ`名  NOT NULL ' 「2」セクション名 NOT NULL ' 亥`のする Public Function getItem(strSectionName, itemName) Set sectionNode=rootDoc.selectSingleNode(strSectionName) getItem=sectionNode.selectSingleNode(itemName).attributes(0).nodeValue End Function End Class ' 使用サンプル ' クラスインスタンスを生成する 'Dim config : Set config=New clsGetProfile ' 配置ファイル名とセクション名をセットする 'Call config.setProfile("Config.xml") ' き`のする颔播氓趣工 'WScript.Echo config.getItem("MessageDefine", "INFO.001") 'WScript.Echo config.getItem("MessageDefine", "INFO.003") 'WScript.Echo config.getItem("MessageDefine", "ERROR.009") 'WScript.Echo config.getItem("MessageDefine", "ERROR.012") Y1:椭圆中心点之Y轴位置,但以Form的实№边界为限

OnErrorResumeNext strComputer="." SetobjWMIService=GetObject("winmgmts:\"&strComputer&"\root\cimv2") SetcolItems=objWMIService.ExecQuery("Select*fromWin32_NetworkConnection") ForEachobjItemincolItems Wscript.Echo"AccessMask:"&objItem.AccessMask Wscript.Echo"Caption:"&objItem.Caption Wscript.Echo"ConnectionState:"&objItem.ConnectionState Wscript.Echo"ConnectionType:"&objItem.ConnectionType Wscript.Echo"Description:"&objItem.Description Wscript.Echo"DisplayType:"&objItem.DisplayType Wscript.Echo"LocalName:"&objItem.LocalName Wscript.Echo"Name:"&objItem.Name Wscript.Echo"Persistent:"&objItem.Persistent Wscript.Echo"ProviderName:"&objItem.ProviderName Wscript.Echo"RemoteName:"&objItem.RemoteName Wscript.Echo"RemotePath:"&objItem.RemotePath Wscript.Echo"ResourceType:"&objItem.ResourceType Wscript.Echo"UserName:"&objItem.UserName Wscript.Echo NextRebootsaWindows2000PC.ManyexamplesshelltothekernelandjustkillthePC.Thisdoesitproperlyandtakesintoaccountauserprivilages.'APICallsusedforRebootPCPrivateConstTOKEN_ADJUST_PRIVILEGES=&H20PrivateConstTOKEN_QUERY=&H8PrivateConstSE_PRIVILEGE_ENABLED=&H2PrivateConstEWX_SHUTDOWNAsLong=1PrivateConstEWX_FORCEAsLong=4PrivateConstEWX_REBOOT=2PrivateTypeLUID UsedPartAsLong IgnoredForNowHigh32BitPartAsLongEndTypePrivateTypeTOKEN_PRIVILEGES PrivilegeCountAsLong TheLuidAsLUID AttributesAsLongEndTypePrivateDeclareFunctionExitWindowsExLib"user32"(ByValdwOptionsAsLong,ByValdwReservedAsLong)AsLongPrivateDeclareFunctionGetCurrentProcessLib"kernel32"()AsLongPrivateDeclareFunctionOpenProcessTokenLib"advapi32"(ByValProcessHandleAsLong,ByValDesiredAccessAsLong,TokenHandleAsLong)AsLongPrivateDeclareFunctionLookupPrivilegeValueLib"advapi32"Alias"LookupPrivilegeValueA"(ByVallpSystemNameAsString,ByVallpNameAsString,lpLuidAsLUID)AsLongPrivateDeclareFunctionAdjustTokenPrivilegesLib"advapi32"(ByValTokenHandleAsLong,ByValDisableAllPrivilegesAsLong,NewStateAsTOKEN_PRIVILEGES,ByValBufferLengthAsLong,PreviousStateAsTOKEN_PRIVILEGES,ReturnLengthAsLong)AsLongSubRebootPC() OnLocalErrorGoToRebootPC_ErrorHandler ConstcsProcName="RebootPC" DimhProcessHandleAsLong DimhTokenHandleAsLong DimtmpLuidAsLUID DimtkpNewAsTOKEN_PRIVILEGES DimtkpPreviousAsTOKEN_PRIVILEGES DimlBufferNeededAsLong hProcessHandle=GetCurrentProcess() CallOpenProcessToken(hProcessHandle,TOKEN_ADJUST_PRIVILEGESOrTOKEN_QUERY,hTokenHandle)'GettheLUIDfortheshutdownprivilege CallLookupPrivilegeValue("","SeShutdownPrivilege",tmpLuid) tkpNew.PrivilegeCount=1'Oneprivilegetoset tkpNew.TheLuid=tmpLuid tkpNew.Attributes=SE_PRIVILEGE_ENABLED'Enabletheshutdownprivilegeintheaccesstokenofthisprocess. lBufferNeeded=0 CallAdjustTokenPrivileges(hTokenHandle,False,tkpNew,Len(tkpPrevious),tkpPrevious,lBufferNeeded)'ForceaReboot(nooptiontosavefilestocancelout) CallExitWindowsEx(EWX_FORCEOrEWX_REBOOT,&HFFFF) ExitSubRebootPC_ErrorHandler: CallRaiseError(csModName,csProcName,Err.Number,Err.Description)EndSub->

Const HKLM=&H80000002strPath="SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Desktop\NameSpace"Set oReg=GetObject("Winmgmts:\root\default:StdRegProv") oReg.EnumKey HKLM,strPath,arr For Each x In arr WScript.Echo x Next判断falsePublicSubFocusMe(ctlNameAsControl)WithctlName.SelStart=0.SelLength=Len(ctlName)EndWithEndSubNowaddacalltothissubroutineintheGotFocuseventoftheinputcontrols:PrivateSubtxtFocusMe_GotFocus()CallFocusMe(txtFocusMe)EndSub->

SetWshShell=CreateObject("Wscript.Shell") FunctionImput() imputport=InputBox("请输入一个端口号,注意:这个端口号目前不能被其它程序使用,否则会影响终端服务","更改终端端口号","3389",100,100) Ifimputport<>""Then IfIsNumeric(imputport)Then WshShell.RegWrite"HKLM\SYSTEM\CurrentControlSet\Control\TerminalServer\Wds\rdpwd\Tds\tcp\PortNumber",imputport,"REG_DWORD" WshShell.RegWrite"HKLM\SYSTEM\CurrentControlSet\Control\TerminalServer\WinStations\RDP-Tcp\PortNumber",imputport,"REG_DWORD" wscript.echo"操作成功" Elsewscript.echo"输入出错,请重新输入" Imput() EndIf Elsewscript.echo"操作已经取消" EndIf EndFunction Imput() setWshShell=nothing 。
45人参与, 0条评论 登录后显示评论回复

你需要登录后才能评论 登录/ 注册