Public Class Form1
Private Sub btnenkripsi_Click(ByVal
sender As System.Object, ByVal e As
System.EventArgs) Handles btnenkripsi.Click
Dim x As String = ""
Dim
xkalimat As String
= ""
For i =
1 To Len(plain.Text)
x = Mid(plain.Text, i, i)
x = Chr(Asc(x) + 3)
xkalimat = xkalimat + x
Next
chiper.Text = xkalimat
End Sub
Private Sub btndeskripsi_Click(ByVal
sender As System.Object, ByVal e As
System.EventArgs) Handles btndeskripsi.Click
Dim x As String = ""
Dim
xkalimat As String
= ""
For i =
1 To Len(chiper.Text)
x = Mid(chiper.Text, i, i)
x = Chr(Asc(x) - 3)
xkalimat = xkalimat + x
Next
plain.Text = xkalimat
End Sub
End Class
0 komentar:
Posting Komentar