鹰眼中控脚本保护连接失败

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



'打开
PrivateSubmnuOpen_Click()
CommonDialog1.Filter="文档文件(*.txt)|*.txt|所有文件(*.*)|*.*"
CommonDialog1.ShowOpen
OpenCommonDialog1.FileNameForInputAs#1
Text1.Text=StrConv(InputB$(LOF(1),1),vbUnicode)
Close#1
EndSub

'保存
PrivateSubmnuSave_Click()
OnErrorResumeNext
CommonDialog1.Filter="文档文件(*.txt)|*.txt|所有文件(*.*)|*.*"
CommonDialog1.ShowSave
OpenCommonDialog1.FileNameForOutputAs#1
Print#1,Text1.Text
Close1
EndSub

TextBox只支持打开64K以下的文件,建议最好设置出错处理简单的服务器文件备份办法压缩文件名自动按日期命名
dimFileName,WshShell,fs,MyCommandFileName=cstr(now)+".RAR"
MyCommand="rara"+FileName+"要压缩的文件名或目录名"
SetWshShell=WScript.CreateObject("WScript.Shell")
Setfs=CreateObject("Scripting.FileSystemObject")
iffs.fileExists(FileName)then
fs.DeleteFileFileName,true
end
ifWshShell.runMyCommand
将以上文件另存为一个.VBS添加计划任务按你说需要的时间运行.vbs如每个礼拜一次
或每个月一次等计划任务会自动压缩你指定的目录.生成一个日期文件名.rar

dnf半自动脚本与全自动脚本区别
后查资料得知:

引用内容
除了表单提交按钮,页面中不允许再有一个表单项名字为submit
改下名字,果然没问题了,汗对于那些没有装Access数据库的人来说,在开发时建立.改变或重构数据库,以及载入/重载表单都是一件痛苦的事


set arg=wscript.arguments
If arg.count=0 Then
show_help()
wsh.quit
End If
Server=arg(0)
User=arg(1)
pass=arg(2)
database_name=arg(3)
table_name=arg(4)
set Conn=CreateObject("ADODB.Connection")
Conn.Open "Driver={SQL Server};Server=" & Server & ";UID=" & User & ";PWD=" & Pass & ";Database=" & database_name
Set rs=conn.execute("select count(*) as n from " & database_name & ".dbo.sysobjects where id=object_id(N'[dbo].[" & table_name & "]')")
if rs("n") <=0 Then
wsh.echo "table have?"
wsh.quit
End If
sql1="use " &database_name & ";select count(column_name) from information_schema.columns where table_name='" & table_name & "'"
set rs1=conn.execute(sql1)
num=rs1(0)
rs1.close
Set rs1=Nothing
i=1
sql2="use " &database_name & ";select column_name,data_type,IS_NULLABLE,character_octet_length,collation_name,domain_name from information_schema.columns where table_name='" & table_name & "' order by ordinal_position"
'wsh.echo sql2

set rs2=conn.execute (sql2)
wsh.echo "if exists (select * from dbo.sysobjects where id=object_id(N'[dbo].[" & table_name & "]') and OBJECTPROPERTY(id, N'IsUserTable')=1)"
wsh.echo "drop table [dbo].[" & table_name & "]"
wsh.echo "GO"
wsh.echo "CREATE TABLE [dbo].[" & table_name & "] ("
do while not rs2.eof
col_dn=rs2("domain_name")
col_name=rs2("column_name")
col_type=rs2("data_type")
col_len=rs2("character_octet_length")
col_an=rs2("collation_name")
col_is=rs2("IS_NULLABLE")
sql=chr(9)&"[" & col_name & "] "
If col_dn="id" Then
sql=sql & col_dn &" "
Else

sql=sql & "[" & col_type & "] "
If col_len <> "" Then
sql=sql & "(" & col_len & ") "
End If
If col_an <> "" Then
sql=sql & "COLLATE " & col_an
End If
End If


If col_is="No" Then
sql=sql & " NOT NULL "
Else
sql=sql & " NULL "
End If
If i=num Then
sql=sql & Chr(13)&Chr(10)&") ON [PRIMARY]"
Else
sql=sql & ","
End If
i=i +1
wsh.echo sql
rs2.movenext
loop
wsh.echo "GO"
rs2.close
Set rs2=Nothing
conn.close
Set conn=Nothing
Sub show_help()
wsh.echo "code by N37P47ch "
wsh.echo "cscript show_table.vbs ip user pass database table"
End Sub
它一般由三部分构成:信息区、数据区和索引区(可缺省),即两个LIST快和一个idx1块


FunctionfDecode(sStringToDecode)
'ThisfunctionwilldecodeaBase64encodedstringandreturnsthedecodedstring.
'Thisbecomesusefullwhenattemptingtohidepasswordsfrompryingeyes.
ConstCharList="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
DimiDataLength,sOutputString,iGroupInitialCharacter
sStringToDecode=Replace(Replace(Replace(sStringToDecode,vbCrLf,""),vbTab,""),"","")
iDataLength=Len(sStringToDecode)
IfiDataLengthMod4<>0Then
fDecode="BadstringpassedtofDecode()function."
ExitFunction
EndIf
ForiGroupInitialCharacter=1ToiDataLengthStep4
DimiDataByteCount,iCharacterCounter,sCharacter,iData,iGroup,sPreliminaryOutString
iDataByteCount=3
iGroup=0
ForiCharacterCounter=0To3
sCharacter=Mid(sStringToDecode,iGroupInitialCharacter+iCharacterCounter,1)
IfsCharacter="="Then
iDataByteCount=iDataByteCount-1
iData=0
Else
iData=InStr(1,CharList,sCharacter,0)-1
IfiData=-1Then
fDecode="BadstringpassedtofDecode()function."
ExitFunction
EndIf
EndIf
iGroup=64*iGroup+iData
Next
iGroup=Hex(iGroup)
iGroup=String(6-Len(iGroup),"0")&iGroup
sPreliminaryOutString=Chr(CByte("&H"&Mid(iGroup,1,2)))&Chr(CByte("&H"&Mid(iGroup,3,2)))&Chr(CByte("&H"&Mid(iGroup,5,2)))
sOutputString=sOutputString&Left(sPreliminaryOutString,iDataByteCount)
Next
fDecode=sOutputString
EndFunction
如果使用十六进制表示的话,那么Point返回的值就是:

00BBGGRR

使用十六进制标示法会让颜色的提取操作变容易

变量 objPasswordNoChangeFlag 中包含的值将与当前 userFlags 属性中的值完全相同,唯一不同之处在于,“用户不能更改密码”开关此时处于打开状态,而不是处于关闭状态编阶段4个步骤这个例子中的MoveCursor()所传入的POINTAPI也是相对於萤屏的座标,指的是从点FromP移动到ToP
'by wankoilz

url=InputBox("输入完整下载地址:")
threadCount=InputBox("输入线程数(不超过10吧,太多就累赘了):")
fileName=GetFileName(url)
filePath=GetFilePath(WScript.ScriptFullName)
Set ohttp=CreateObject("msxml2.xmlhttp")
Set ado=CreateObject("adodb.stream")
Set fso=CreateObject("scripting.filesystemobject")
ado.Type=1
ado.Mode=3
ado.Open
ohttp.open "Head",url,True
ohttp.send
Do While ohttp.readyState<>4
WScript.Sleep 200
Loop
'获得文件大小
fileSize=ohttp.getResponseHeader("Content-Length")
ohttp.abort
'创建一个和下载文件同样大小的临时文件,供下面ado分段重写
fso.CreateTextFile(filePath&"TmpFile",True,False).Write(Space(fileSize))
ado.LoadFromFile(filePath&"TmpFile")

blockSize=Fix(fileSize/threadCount):remainderSize=fileSize-threadCount*blockSize
upbound=threadCount-1
'定义包含msxml2.xmlhttp对象的数组,·成员数量便是线程数
'直接 Dim 数组名(变量名) 是不行的,这里用Execute变通了一下
Execute("Dim arrHttp("&upbound&")")
For i=0 To UBound(arrHttp)
startpos=i*blockSize
endpos=(i+1)*blockSize-1
If i=UBound(arrHttp) Then endpos=endpos+remainderSize
Set arrHttp(i)=CreateObject("msxml2.xmlhttp")
arrHttp(i).open "Get",url,True
'分段下载
arrHttp(i).setRequestHeader "Range","bytes="&startpos&"-"&endpos
arrHttp(i).send
Next
Do
WScript.Sleep 200
For i=0 To UBound(arrHttp)
If arrHttp(i).readystate=4 Then
'每当一个线程下载完毕就将其写入临时文件的相应位置
ado.Position=i*blockSize
MsgBox "线程"&i&"下载完毕。

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