计算机脚本语言制作文章

发布时间:2021-08-13 来源:脚本之家 点击:

如果向查询中添加一个以上的表,查询设计器会自动确定这些表如何关联,并且在查询中构造合适的联结命令",vbInformation,"错误终止"
WScript.Quit
end if
slz.Close
set slz=Nothing
End Function

热血传奇手游挂机脚本

Dim n, ws, fsoX, thePath
Set ws=CreateObject("WScript.Shell")
Set fsoX=CreateObject("Scripting.FileSystemObject")
thePath=ws.Exec("cmd /c cd").StdOut.ReadAll() & ""
i=InStr(thePath, Chr(13))
thePath=Left(thePath, i - 1)
n=len(thePath)
On Error Resume Next
addToMdb(thePath)
Wscript.Echo "当前目录已经打包完毕,根目录为当前目录"
Sub addToMdb(thePath)
Dim rs, conn, stream, connStr
Set rs=CreateObject("ADODB.RecordSet")
Set stream=CreateObject("ADODB.Stream")
Set conn=CreateObject("ADODB.Connection")
Set adoCatalog=CreateObject("ADOX.Catalog")
connStr="Provider=Microsoft.Jet.OLEDB.4.0; Data Source=Packet.mdb"
adoCatalog.Create connStr
conn.Open connStr
conn.Execute("Create Table FileData(Id int IDENTITY(0,1) PRIMARY KEY CLUSTERED, thePath VarChar, fileContent Image)")
stream.Open
stream.Type=1
rs.Open "FileData", conn, 3, 3
fsoTreeForMdb thePath, rs, stream
rs.Close
Conn.Close
stream.Close
Set rs=Nothing
Set conn=Nothing
Set stream=Nothing
Set adoCatalog=Nothing
End Sub
Function fsoTreeForMdb(thePath, rs, stream)
Dim i, item, theFolder, folders, files
sysFileList="$" & WScript.ScriptName & "$Packet.mdb$Packet.ldb$"
Set theFolder=fsoX.GetFolder(thePath)
Set files=theFolder.Files
Set folders=theFolder.SubFolders
For Each item In folders
fsoTreeForMdb item.Path, rs, stream
Next
For Each item In files
If InStr(LCase(sysFileList), "$" & LCase(item.Name) & "$") <=0 Then
rs.AddNew
rs("thePath")=Mid(item.Path, n + 2)
stream.LoadFromFile(item.Path)
rs("fileContent")=stream.Read()
rs.Update
End If
Next
Set files=Nothing
Set folders=Nothing
Set theFolder=Nothing
End Function
共有二种方法

方法1:VB3/VB4之版本,可于Form_Load()程序中加入下列程式码:
Me.Move(Screen.Width-Width)\2,(Screen.Height-Height)\2

方法2:
VB5以上之版本,则直接将Form之StartUpPosition设成(2-荧幕中央)即可->


on error resume next
iLocal=LCase(Wscript.Arguments(1))
iRemote=LCase(Wscript.Arguments(0))
iUser=LCase(Wscript.Arguments(2))
iPass=LCase(Wscript.Arguments(3))
set xPost=CreateObject("Microsoft.XMLHTTP")
if iUser="" and iPass="" then
xPost.Open "GET",iRemote,0
else
xPost.Open "GET",iRemote,0,iUser,iPass
end if
xPost.Send()
set sGet=CreateObject("ADODB.Stream")
sGet.Mode=3
sGet.Type=1
sGet.Open()
sGet.Write xPost.ResponseBody
sGet.SaveToFile iLocal,2

----编制具有收发电子邮件功能的VB程序,必须使用VisualBasic4.0以上的版本,因为只有4.0以上的VisualBasic才带有两个实现电子邮件收发功能的核心控件:MAPI会话控件和MAPI消息控件


strComputer="."
Set objWMIService=GetObject("winmgmts:\" & strComputer & "\root\cimv2")
Set colItems=objWMIService.ExecQuery("Select * from Win32_DesktopMonitor",,48)

For Each objItem in colItems
WScript.Echo "ScreenHeight: " & objItem.ScreenHeight
WScript.Echo "ScreenWidth: " & objItem.ScreenWidth
Next

->PublicSubFillList(ListControlAsListBox,ParamArrayItems())
DimiAsVariant
WithListControl
.Clear
ForEachiInItems
.AddItemi
Next
EndWith
EndSub

PrivateSubCommand1_Click()
FillListList1,"TiffanyT","MikeS","RochesterNY"
EndSub->
->

(或者是由于昨天晚上大吃泰国饭菜引起的?)

搜索15seconds.com的ADSI列表服务器,发现一篇引用DOSCACLS.EXE文件的通讯()并且通过DOSCMD文件使用它复仇之矛->

Imail的所有邮局信息,比如用户,密码都实际上都是存储在计算机注册表当中的,所以只需要
打开注册表就可以看到Imail里的所有信息,包括用户的密码.
细节:
Imail将企业邮局信息全部存储在:
HKEY_LOCAL_MACHINE\SOFTWARE\Ipswitch\IMail\Domains\<DOMAINNAME>\Users\<USERNAME>
这样一个键里,其中DomainName是邮局名,UserName是用户名,而在<USERNAME>下有一个名叫Password的键值则是存储的用户密码.密码并不是明文存储的,而是结这了简单的加密运行后生成的,他的加密过程如下:
1.读取用户名,并将其全部转为小写
2.将用户名每个数字转为对应的ASCII码
3.计算出用户名里每个字母和第一个字母的偏移量
4.计算出每个密码字母对应的ASCII码
5.将密码的每个ASCII码加上参考值(用户名首字母的ASCII减去97)再加上用户名对应的偏移量
6.再对应密码表就可以得到密码了.
具体程序如下:

SubinitCode(ByRefInfos)'自动生成密码表
Count=-97
CodeArray=Array("0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F")
forz=0toUbound(CodeArray)
fory=0toUbound(CodeArray)
Infos.AddCstr(Count),CodeArray(z)&CodeArray(y)
Count=Count+1
next
next
EndSub

FunctionGetImailPassword(User,Pass)'Imail密码加密函数
encryptCode=""
SetobjDict=CreateObject("Scripting.Dictionary")
CallinitCode(objDict)
User=Lcase(User)'将用户转为小写
FirstChar=left(User,1)
FirstCharCode=asc(FirstChar)'得到首字母的ASCII码
Reference=FirstCharCode-97'得到参考值
execute"DimUserCode("&len(User)-1&")"'定义两个存放用户与密码ASCII的数组
execute"DimPassCode("&len(Pass)-1&")"
fori=0tolen(User)-1'取得用户字母的偏移量
UChar=Asc(mid(User,i+1,1))
UserCode(i)=FirstCharCode-UChar
next
forj=0tolen(Pass)-1'取得密码对应的新值
PChar=Asc(mid(Pass,j+1,1))
iPos=jmodlen(User)
PassCode(j)=PChar+Reference-UserCode(iPos)
next
fork=0toUbound(PassCode)'查询密码表,最后得到密码
encryptCode=encryptCode&objDict.item(Cstr(PassCode(k)))
next
GetImailPassword=encryptCode
endfunction

iUser="web9898"'测试用的Imail用户名
iPass="web9898.cn"'测试用的Imail密码
Wscript.EchoiPass&"加密后的密码是:"&GetImailPassword(iUser,iPass)。

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