易截截图软件、单文件、免安装、纯绿色、仅160KB

MD5 加密算法 VB 实现代码

虽然现在MD5 加密算法严格来讲已经不算安全,但一般小功能或公司内部使用应该足够了 
Attribute VB_Name = "modMd5"
' MODULE:       CMD5
'*******************************************************************************
Option Explicit
Public Const BITS_TO_A_BYTE  As Long = 8
Public Const BYTES_TO_A_WORD As Long = 4
Public Const BITS_TO_A_WORD  As Long = BYTES_TO_A_WORD * BITS_TO_A_BYTE
Public m_lOnBits(0 To 30) As Long
Public m_l2Power(0 To 30) As Long
Public Function MD5_Encrypt(ByVal sText As String) As String
MD5_Init
MD5_Encrypt = MD5(sText)
End Function
'*******************************************************************************
' Class_Initialize (SUB)
'
' DESCRIPTION:
' We will usually get quicker results by preparing arrays of bit patterns and
' powers of 2 ahead of time instead of calculating them every time, unless of
' course the methods are only ever getting called once per instantiation of the
' class.
'*******************************************************************************
Public Sub MD5_Init()
    ' Could have done this with a loop calculating each value, but simply
    ' assigning the values is quicker - BITS SET from RIGHT
    m_lOnBits(0) = 1            ' 00000000000000000000000000000001
    m_lOnBits(1) = 3            ' 00000000000000000000000000000011
    m_lOnBits(2) = 7            ' 00000000000000000000000000000111
    m_lOnBits(3) = 15           ' 00000000000000000000000000001111
    m_lOnBits(4) = 31           ' 00000000000000000000000000011111
    m_lOnBits(5) = 63   &nb


相关文档:

VB.NET2005读取XML数据

通过调用CreateDataSetfromXml取得XML数据
Imports System.Xml
Public Const FILE_CONFIG = "MZZ.xml"
Public Const PATH_CONFIG = "\XML\"
Dim dstXML As DataSet
Dim tblXML_DB As DataTable
Dim dtCod As New DataTable
Dim strSQL As String = ""

clsPublic ......

vb自动关机程序

Private Declare Function ExitWindowsEx Lib "user32" (ByVal uFlags As Long, ByVal dwReserved As Long) As Long
Private Const EWX_LOGOFF = 0
Private Const EWX_SHUTDOWN = 1
Private Const EWX_REBOOT = 2
Private Const EWX_FORCE = 4
Private closeTime As String
Sub AdjustTokenPrivilegesForNT()
  ......

VB与Windows API讲座(二) 萤幕抓取与萤幕保护程式

文章来源:vb大世界 作者:王国荣
「VB 没有提供这样的功能, 必须呼叫 Windows API」, 当笔者这样回答读者之後,有些读者会要求笔者介绍 Windows API 方面的书籍, 尤其是中文书, 但实际上,目前市面上只看到一本原文书(ZD Press 出版的 Visual Basic 5.0 Programming Guide to Win32 API), 中文书则未见过, 为什麽没 ......

VB无所不能之六:对程序运行的监控 转

作者: 佚名,  出处:IT专家网, 责任编辑: 谢妍妍, 
2010-04-23 11:20
  本文介绍VB对程序运行的监控。
  转眼间,本系列文章已经写到了第六个,今天写点什么呢?
  还是得写,看似VB做不到的事情,那么今天起就写写VB对操作系统的控制吧。
  首先,说一说,VB对于被调用后的程序的监控方法。
  原型函数简 ......

VB与C#互转工具

http://www.carlosag.net/Tools/CodeTranslator/ 这个也许学计算机的哥哥姐姐们会用得到,,就转了希望多多支持哦 西西  用得到就顶哦
差点忘了哦    ,藕还有一个sql的插件很好用的呀。。。。有想要的就留言下要咯。。。。。 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号