Voilà je commence le VB.net et voilà mon premier programme entièrement de moi =)
Le logiciel consiste à coder une phrase très facilement et de décoder une phrase codée par celui-ci
Ce lien n'est pas visible, veuillez vous connecter pour l'afficher. Je m'inscris!
Merci de laisser une critique ou autre =)
Le logiciel consiste à coder une phrase très facilement et de décoder une phrase codée par celui-ci
Ce lien n'est pas visible, veuillez vous connecter pour l'afficher. Je m'inscris!
Public Class Codeur
Private Sub TXT_DEPART_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TXT_DEPART.TextChanged
End Sub
Private Sub BT_TRANSFO_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BT_TRANSFO.Click
Dim Phrase As String = Me.TXT_DEPART.Text
Phrase = Phrase.Replace("a", "1")
Phrase = Phrase.Replace("c", "2")
Phrase = Phrase.Replace("e", "3")
Phrase = Phrase.Replace("g", "4")
Phrase = Phrase.Replace("i", "5")
Phrase = Phrase.Replace("k", "6")
Phrase = Phrase.Replace("n", "7")
Phrase = Phrase.Replace("o", "8")
Phrase = Phrase.Replace("q", "9")
Phrase = Phrase.Replace("s", "§")
Phrase = Phrase.Replace("u", "é")
Phrase = Phrase.Replace("w", "ç")
Phrase = Phrase.Replace("z", "0")
Phrase = Phrase.Replace("m", "$")
Phrase = Phrase.Replace("b", "µ")
Me.TXT_FIN.Text = Phrase
End Sub
Private Sub TXT_BOX_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TXT_FIN.TextChanged
End Sub
Private Sub BT_DECODER_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BT_DECODER.Click
Dim Phrase2 As String = Me.TXT_FIN.Text
Phrase2 = Phrase2.Replace("1", "a")
Phrase2 = Phrase2.Replace("2", "c")
Phrase2 = Phrase2.Replace("3", "e")
Phrase2 = Phrase2.Replace("4", "g")
Phrase2 = Phrase2.Replace("5", "i")
Phrase2 = Phrase2.Replace("6", "k")
Phrase2 = Phrase2.Replace("7", "n")
Phrase2 = Phrase2.Replace("8", "o")
Phrase2 = Phrase2.Replace("9", "r")
Phrase2 = Phrase2.Replace("§", "s")
Phrase2 = Phrase2.Replace("é", "u")
Phrase2 = Phrase2.Replace("ç", "w")
Phrase2 = Phrase2.Replace("0", "z")
Phrase2 = Phrase2.Replace("$", "m")
Phrase2 = Phrase2.Replace("µ", "b")
Me.TXT_DEPART.Text = Phrase2
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Me.TXT_DEPART.Clear()
Me.TXT_FIN.Clear()
End Sub
Private Sub Label4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label4.Click
End Sub
End Class
Private Sub TXT_DEPART_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TXT_DEPART.TextChanged
End Sub
Private Sub BT_TRANSFO_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BT_TRANSFO.Click
Dim Phrase As String = Me.TXT_DEPART.Text
Phrase = Phrase.Replace("a", "1")
Phrase = Phrase.Replace("c", "2")
Phrase = Phrase.Replace("e", "3")
Phrase = Phrase.Replace("g", "4")
Phrase = Phrase.Replace("i", "5")
Phrase = Phrase.Replace("k", "6")
Phrase = Phrase.Replace("n", "7")
Phrase = Phrase.Replace("o", "8")
Phrase = Phrase.Replace("q", "9")
Phrase = Phrase.Replace("s", "§")
Phrase = Phrase.Replace("u", "é")
Phrase = Phrase.Replace("w", "ç")
Phrase = Phrase.Replace("z", "0")
Phrase = Phrase.Replace("m", "$")
Phrase = Phrase.Replace("b", "µ")
Me.TXT_FIN.Text = Phrase
End Sub
Private Sub TXT_BOX_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TXT_FIN.TextChanged
End Sub
Private Sub BT_DECODER_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BT_DECODER.Click
Dim Phrase2 As String = Me.TXT_FIN.Text
Phrase2 = Phrase2.Replace("1", "a")
Phrase2 = Phrase2.Replace("2", "c")
Phrase2 = Phrase2.Replace("3", "e")
Phrase2 = Phrase2.Replace("4", "g")
Phrase2 = Phrase2.Replace("5", "i")
Phrase2 = Phrase2.Replace("6", "k")
Phrase2 = Phrase2.Replace("7", "n")
Phrase2 = Phrase2.Replace("8", "o")
Phrase2 = Phrase2.Replace("9", "r")
Phrase2 = Phrase2.Replace("§", "s")
Phrase2 = Phrase2.Replace("é", "u")
Phrase2 = Phrase2.Replace("ç", "w")
Phrase2 = Phrase2.Replace("0", "z")
Phrase2 = Phrase2.Replace("$", "m")
Phrase2 = Phrase2.Replace("µ", "b")
Me.TXT_DEPART.Text = Phrase2
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Me.TXT_DEPART.Clear()
Me.TXT_FIN.Clear()
End Sub
Private Sub Label4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label4.Click
End Sub
End Class
Merci de laisser une critique ou autre =)