Dim Val1 As String = "龙的传人" Dim Val2 As String = EncryptText(Val1,"a23","op#") '加密 try Dim Val3 As String = DecryptText("228HqJrxgDHJQFHwqhK3Mg=1","a23","op#") '解密,两个密钥必须和加密的时候相同 Output.Show("加密后:" & val2) Output.Show("解密后:" & val3) catch ex As exception msgbox("解密出错") End try