Public Function PutPWD(StrPWD As String) As String 'StrPWD加密 Dim i As Integer PutPWD = "" For i = 1 To Len(StrPWD) PutPWD = PutPWD & Chr(Asc(Mid(StrPWD, i, 1)) - Len(StrPWD)) Next End FunctionPublic Function GetPWD(StrPWD As String) As String 'StrPWD解密 Dim i As Integer GetPWD = "" For i = 1 To Len(StrPWD) GetPWD = GetPWD & Chr(Asc(Mid(StrPWD, i, 1)) + Len(StrPWD)) Next End Function
Dim i As Integer
PutPWD = ""
For i = 1 To Len(StrPWD)
PutPWD = PutPWD & Chr(Asc(Mid(StrPWD, i, 1)) - Len(StrPWD))
Next
End FunctionPublic Function GetPWD(StrPWD As String) As String 'StrPWD解密
Dim i As Integer
GetPWD = ""
For i = 1 To Len(StrPWD)
GetPWD = GetPWD & Chr(Asc(Mid(StrPWD, i, 1)) + Len(StrPWD))
Next
End Function
请问这两个函数在什么时候使用,StrPWD是不是用来传入密码的值。
a=密码
b=putPWD(a) '加密密码
c=getPWD(b) '取回密码
就这麽简单,顺便问一下,你用的是什么语言啊?