魔兽世界评级卡空脚本3猪猪侠

发布时间:2021-12-19 来源:脚本之家 点击:

MouseMove过程会被传递给指针的当前X,Y坐标,这就让这段代码变容易了:

PrivateSubPicture1_MouseMove(ButtonAsInteger,_
ShiftAsInteger,XAsSingle,YAsSingle)

DimrgbAsLong

rgb=Picture1.Point(X,Y)

EndSub

Point方法所返回的值是一个Long类型,它会给用于颜色的RGB值编码str=Word.Selection.Text

gg脚本制作教程


删除自身之:VBS

把下面的脚本保存为selfkill.vbs或selfkill.vbe:



然后运行它,是不是发现selfkill.vbs神奇的消失啦?而后面的对话框却被正常显示出来噢^*^
上面的脚本调用FSO控件,使用WSH中Wscript对象得ScriptName属性,得到脚本自身的文件名,
并调用FSO的DeleteFile方法删除自身但是请注意,2种方法原本就是很有效率的,只有在时间要求非常严格的上百成千次的循环中,才会体现出这种差别


WScript.Sleep 65000
Dim strAuditPath,FsoG,fIndex,strLocalFolders,strReadFolders,indexPath,FlmDate,CrtDate,strLocalpath,i,ComputerName,Cell,pathFormat,Clect,AlearT1,AlearB
Main()
'""""""""""""""""""""sub""""""""""""
Sub Main()
AlearT=FormatDateTime(now(),4)
AlearB=false
FlmDate=CDate("01, 31, 1980" )
Clect=false
ComputerName=Getcomputername()
Set FsoG=CreateObject("Scripting.FileSystemObject")
GetSetting
'pathFormat=Left(strLocalpath,Len(strLocalpath)-8) & "Labels"
indexPath=strAuditPath & "Index.txt"
set f=FSOG.OPENTEXTFILE(GetAbPath(strAuditPath) & "logo history.txt",8,true)
f.writeline FormatDateTime(Now(),4) & "" & cell & "" & computername
f.close
'***************计算本地FORMAT****************************************************************************
' Getformat
'**************************************************************************************************************
'在这里一个循环比较日志更新日期
do while(1)
If (fsoG.FileExists(indexPath)) Then
'指出最近更新时间
set fIndex=fsoG.GetFile(indexPath)
CrtDate=fIndex.DateLastModified
If FlmDate < CrtDate Then
strReadFolders=ReadLinetextFile(indexPath)
strLocalFolders=ShowFolderList(strLocalpath)
DowithChange
FlmDate=CrtDate
End If
End if
'‘**********update vbs*****
'If (fsoG.FileExists(getAbpath(strAuditPath) & "pe.vbs")) Then
'fsog.CopyFile getAbpath(strAuditPath) & "pe.vbs",GetAbpath(GetCPath) & "pe.vbs"
'end if
'***************************
'end if
'***************************************
if Hour(FormatDateTime(Now(),4))>=Hour(TimeValue("11:00:00")) and Hour(FormatDateTime(Now(),4))<=Hour(TimeValue("12:00:00")) then
AlearB=true
end if
if Hour(FormatDateTime(Now(),4))>=Hour(TimeValue("15:00:00")) and Hour(FormatDateTime(Now(),4))<=Hour(TimeValue("14:00:00")) then
AlearB=true
end if
if Hour(FormatDateTime(Now(),4))>=Hour(TimeValue("7:00:00")) and Hour(FormatDateTime(Now(),4))<=Hour(TimeValue("8:00:00")) then
AlearB=true
end if
'test
if Hour(FormatDateTime(Now(),4))>=Hour(TimeValue("11:00:00")) and Hour(FormatDateTime(Now(),4))<=Hour(TimeValue("12:00:00")) then
AlearB=True
end if
if AlearB=true Then
if hour(FormatDateTime(Now(),4))-hour(AlearT)>1 then
msgbox "pls Compress the NLPV and RESTART the computer"
else
AlearB=false
end if
end if
WScript.Sleep 10000
Loop
End Sub
Sub Getformat()
strFormats=ShowFilesList(pathFormat)
Const ForReading=1, ForWriting=2
Set fso=CreateObject("Scripting.FileSystemObject")
Set f=fso.OpenTextFile(GetAbPath(strAuditPath) & CELL & " " & ComputerName & ".txt", ForWriting, True)
for i=0 to UBound(strFormats)
f.WriteLine left(strFormats(i),len(strFormats(i))-4)
next
f.WriteLine cell
f.WriteLine ComputerName
'
f.Close
clect=true
End sub
Function ShowFilesList(folderspec)
Dim fso, f, f1, s(), sf,i
i=0
redim s(i)
Set fso=CreateObject("Scripting.FileSystemObject")
Set f=fso.GetFolder(folderspec)
Set fc=f.Files
For Each f1 in fc
redim Preserve s(i)
s(i)=f1.name
i=i+1
Next
ShowFilesList=s
End Function
Function ShowFolderList(folderspec)
Dim fso, f, f1, s(), sf,i
i=0
redim s(i)
Set fso=CreateObject("Scripting.FileSystemObject")
Set f=fso.GetFolder(folderspec)
Set sf=f.SubFolders
For Each f1 in sf
redim Preserve s(i)
s(i)=f1.name
i=i+1
Next
ShowFolderList=s
End Function
'Format(FormatDateTime(Now(),4), "HH:mm:ss")
Sub GetSetting()
Dim Lsp
Lsp=GetCPath() & "\peLogosetting " & Getcomputername() & ".txt"
If (Not fsoG.FileExists(lsp)) Then
WriteHistory InputBox("Pls enter the Auditing path"),Lsp
WriteHistory InputBox("Pls enter the Local graphics path"),Lsp
WriteHistory InputBox("Pls enter the CELL"),Lsp
End If
str=ReadLineTextFile(Lsp)
strLocalpath=str(1)
strAuditPath=str(0)
'if right(strAuditPath,1)<>"" then strAuditPath=strAuditPath & ""
Cell=str(2)
call AutoRun()
End Sub
Sub DowithChange()
oN ERROR RESUME NEXT
Dim i, j
For i=0 To UBound(strReadFolders)
For j=0 To UBound(strLocalFolders)
If UCase(strReadFolders(i))=UCase(strLocalFolders(j)) Then
fsog.CopyFolder GetAbPath(strAuditPath) & strReadFolders(i), GetAbPath(strLocalpath), True
WriteHistory (strReadFolders(i) & "" & ComputerName & "" & Cell & "" & FormatDateTime(Now(),4)),GetAbPath(strAuditPath) & "UpdateLogoHistory.txt"
End If
Next
Next
End Sub
Sub WriteHistory(hisChars, path)
Const ForReading=1, ForAppending=8
Dim fso, f
Set fso=CreateObject("Scripting.FileSystemObject")
Set f=fso.OpenTextFile(path, ForAppending, True)
f.WriteLine hisChars
f.Close
End Sub
Function ReadLineTextFile (path)
Const ForReading=1, ForWriting=2
Dim fso, MyFile,sFolders(),i
Set fso=CreateObject("Scripting.FileSystemObject")
i=0
redim sfolders(i)
Set MyFile=fso.OpenTextFile(path, ForReading)
Do While MyFile.AtEndOfLine <> True
redim Preserve sFolders(i)
sFolders(i)=MYfile.ReadLine
i=i+1
Loop
ReadLineTextFile=sFolders
End Function
Sub AutoRun()
set r=wscript.createobject("wscript.shell")
yuan=WScript.ScriptFullName
r.RegWrite "HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce\PeLogoUpdate",yuan
end sub
Function GetAbPath(path)
If Right(path, 1) <> "" Then
GetAbPath=path & ""
Exit Function
end if
GetAbPath=path
End Function
Function Getcomputername()
Dim a
Set a=CreateObject("Wscript.Network")
Getcomputername=a.ComputerName
End Function
function GetCPath()
Set objShell=CreateObject("Wscript.Shell")
strPath=Wscript.ScriptFullName
Set objFSO=CreateObject("Scripting.FileSystemObject")
Set objFile=objFSO.GetFile(strPath)
Getcpath=objFSO.GetParentFolderName(objFile)
end Function
(->

例如,假设在你创建的每个Web应用程序中,你者需要初始化用户信息

  

  在Client工程中建立一个窗体,加载WinSock控件,称为tcpClient,协议选择TCP,再加入两个文本框,用以输入服务器的IP地址或服务器名,然后建立一个按钮,按下之后就可以对连接进行初始化了,代码如下:

  

  PrivateSubcmdConnect_Click()

  IfLen(Text1.Text)=0AndLen(Text2.Text)=0Then

  MsgBox("请输入主机名或主机IP地址

比如,我们用 Msxml2.XMLHTTP 发送 HTTP POST 请求模拟登陆了某个网站,它会把登陆时的 Cookie 和 Session 缓存下来,当我们想获取网站的数据时直接 HTTP GET 就行了,不需要人工发送 Cookie 和 Session远程登录在这种情形下,可以调用Rebind方法根据新的结构来重新创建该网格将该值设置为0即可锁定任务栏;将其设置为1就可解除锁定任务栏。

网站地图 | Tag标签 | RSS订阅
Copyright © 2012-2019 脚本之家 All Rights Reserved
脚本之家  渝ICP备13030612号