Very simple, it just runs a timer with an interval of 10ms and auto updates as you type, anything typed into the first text box shows up in the second textbox in md5 encryption.
This is very basic but i use it when adding user accounts to a database so i dont have to go on a web based one where they load it into a database.
Screen shot:
Download:
http://default.site40.net/release/md5.zip
Source:
Form1.vb
Code:Imports System.Security.Cryptography Imports System.Text Public Class Form1 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load TextBox2.Text = MD5(TextBox1.Text) Timer1.Interval = "10" Timer1.Start() End Sub Public Function MD5(ByVal Source) As String Dim Bytes() As Byte = ASCIIEncoding.ASCII.GetBytes(Source) Dim MD5H As New MD5CryptoServiceProvider Dim Byt() As Byte = MD5H.ComputeHash(Bytes) Dim i As Integer = (Byt.Length * 2 + (Byt.Length / 8)) Dim StrBuild As StringBuilder = New StringBuilder(i) Dim i2 As Integer For i2 = 0 To Byt.Length - 1 StrBuild.Append(BitConverter.ToString(Byt, i2, 1)) Next i2 Return StrBuild.ToString().TrimEnd(New Char() {" "c}).ToLower End Function Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick TextBox2.Text = MD5(TextBox1.Text) End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Clipboard.SetDataObject(Me.TextBox2.SelectedText) Me.TextBox2.SelectAll() Me.TextBox2.Copy() End Sub End Class




Reply With Quote![[VB.Net]MD5 Encrypter](http://ragezone.com/hyper728.png)


