Source Code Program Encrypt

Function Encrypt(What As String) As String
Dim Before$, After$, EpN%, Dracula%, Aeneima$, DeMoNs$
Before$ = ” ?!@#$%^&*()_+|0123456789abcdefghijklmnopqrstuvwxyz.,-~ABCDEFGHIJKLMNOPQRSTUVWXYZ¿¡²³ÀÁÂÃÄÅÒÓÔÕÖÙÛÜàáâãäåض§Ú¥”
After$ = ” ¿¡@#$%^&*()_+|01²³456789ÀbÁdÂÃghÄjklmÅÒÓqÔÕÖÙvwÛÜz.-~,AàáâãFGHäJKåMNضQR§TÚVWX¥Z?!23acefinoprstuxyBCDEILOPSUY”
For EpN% = 1 To Len(What)
Dracula% = InStr(Before$, Mid(What, EpN%, 1))
If Not Dracula% = 0 Then
Aeneima$ = Mid(After$, Dracula%, 1)
DeMoNs$ = DeMoNs$ + Aeneima$
End If
Next
Encrypt = DeMoNs$
End Function

Function DeEncrypt(What As String) As String
Dim Before$, After$, EpN%, Dracula%, Aeneima$, DeMoNs$
Before$ = ” ¿¡@#$%^&*()_+|01²³456789ÀbÁdÂÃghÄjklmÅÒÓqÔÕÖÙvwÛÜz.-~,AàáâãFGHäJKåMNضQR§TÚVWX¥Z?!23acefinoprstuxyBCDEILOPSUY”
After$ = ” ?!@#$%^&*()_+|0123456789abcdefghijklmnopqrstuvwxyz.,-~ABCDEFGHIJKLMNOPQRSTUVWXYZ¿¡²³ÀÁÂÃÄÅÒÓÔÕÖÙÛÜàáâãäåض§Ú¥”
For EpN% = 1 To Len(What)
Dracula% = InStr(Before$, Mid(What, EpN%, 1))
If Not Dracula% = 0 Then
Aeneima$ = Mid(After$, Dracula%, 1)
DeMoNs$ = DeMoNs$ + Aeneima$
End If
Next
DeEncrypt = DeMoNs$
End Function

Private Sub cmdencrypt_Click()
TxtMain.Text = Encrypt(TxtMain.Text)
End Sub

Private Sub cmddecrypt_Click()
TxtMain.Text = DeEncrypt(TxtMain.Text)
End Sub

Tinggalkan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s