手机
当前位置:查字典教程网 >脚本专栏 >vbs >用VBS实现PHP的md5_file函数代码
用VBS实现PHP的md5_file函数代码
摘要:复制代码代码如下:Functionmd5_file(filename,raw_output)DimHashedData,Utility,St...

复制代码 代码如下:

Function md5_file(filename, raw_output)

Dim HashedData, Utility, Stream

Set HashedData = CreateObject("CAPICOM.HashedData")

Set Utility = CreateObject("CAPICOM.Utilities")

Set Stream = CreateObject("ADODB.Stream")

HashedData.Algorithm = 3

Stream.Type = 1

Stream.Open

Stream.LoadFromFile filename

Do Until Stream.EOS

HashedData.Hash Stream.Read(1024)

Loop

If raw_output Then

md5_file = Utility.HexToBinary(HashedData.Value)

Else

md5_file = HashedData.Value

End If

End Function

参考链接:HashedData Object

原文:http://demon.tw/programming/vbs-php-md5_file.html

【用VBS实现PHP的md5_file函数代码】相关文章:

用vbs实现的输入助手附使用方法

用vbs实现的利用ADSL拨号变ip刷投票的代码

用vbs实现不死帐号的代码

用VBS记录客户机操作的代码

用vbscript脚本实现返回 IP 配置数据的代码

用vbs实现的exe2swf工具脚本代码

IE中用VBScript不提示直接打印的代码

vbs实现的eMule电驴自动关机脚本代码

简单的VBS加密实现代码

用VBS脚本实现更换Windows Xp序列号的代码

精品推荐
分类导航