- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
Public Class Decoder
Dim arr_en() As String = {"q", "w", "e", "r", "t", "y", "u", "i", "o", "p", "[", "]", "a", "s", "d", "f", "g", "h", "j", "k", "l", ";", "'", "z", "x", "c", "v", "b", "n", "m", ",", ".", "/", "?", "@"}
Dim arr_ua() As String = {"й", "ц", "у", "к", "е", "н", "г", "ш", "щ", "з", "х", "ъ", "ф", "ы", "в", "а", "п", "р", "о", "л", "д", "ж", "є", "я", "ч", "с", "м", "и", "т", "ь", "б", "ю", ".", ",", "'"}
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
TextBox2.Clear()
Dim t As Char
Dim ch As Char
Dim vv As String
For Each vv In TextBox1.Lines
For Each t In vv
For i As Integer = 0 To arr_en.Count - 1
ch = arr_en.GetValue(i)
If t = ch Then
t = arr_ua.GetValue(i)
Exit For
End If
Next
TextBox2.Text = TextBox2.Text & t
Next
TextBox2.Text = TextBox2.Text & vbCrLf
Next
End Sub
End Class
Lure Of Chaos 04.04.2011 18:56 # 0
bugmenot 04.04.2011 19:11 # 0
undiscovered 04.04.2011 23:08 # 0
7ion 04.04.2011 23:32 # 0
Но там нету разве функции замены строковой, чтоб с массивами работала? Как в похапе.
bugmenot 12.06.2011 22:07 # 0
7ion 13.06.2011 10:30 # 0
guest 12.06.2011 22:19 # 0
17 лет древние времена это интересно когда?
bugmenot 12.06.2011 23:26 # 0
7ion 13.06.2011 10:33 # 0
По-моему, дам даже камера вынута.
Но для коллекции сойдет.
7ion 13.06.2011 10:30 # 0
fodin 12.06.2011 21:50 # 0
Кстати, а где обработка ЗАГЛАВНЫХ букв?