1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
|
Private Sub cmdAdd_Click()
Dim iRow As Long
Dim ws As Worksheet
Set ws = Worksheets("amajyi")
iRow = ws.Cells(Rows.Count, 1) _
.End(xlUp).Offset(1, 0).Row
If (Left(txtKiny.Text, 3) = "umu") Or (Left(txtKiny.Text, 3) = "umw") Or (Left(txtKiny.Text, 2) = "mu") Or (Left(txtKiny.Text, 2) = "mw") Then
ws.Cells(iRow, 1).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "aba") Or (Left(txtKiny.Text, 2) = "ab") Or (Left(txtKiny.Text, 2) = "ba") Then
ws.Cells(iRow, 2).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "imi") Or (Left(txtKiny.Text, 3) = "imy") Or (Left(txtKiny.Text, 2) = "mi") Or (Left(txtKiny.Text, 2) = "my") Then
ws.Cells(iRow, 3).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "iri") Or (Left(txtKiny.Text, 3) = "iry") Or (Left(txtKiny.Text, 2) = "ri") Or (Left(txtKiny.Text, 2) = "ry") Then
ws.Cells(iRow, 4).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "ama") Or (Left(txtKiny, 2) = "am") Or (Left(txtKiny.Text, 2) = "ma") Then
ws.Cells(iRow, 5).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "iki") Or (Left(txtKiny.Text, 3) = "icy") Or (Left(txtKiny.Text, 3) = "igi") Then
ws.Cells(iRow, 6).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "ibi") Or (Left(txtKiny.Text, 3) = "ibyi") Or (Left(txtKiny.Text, 2) = "ki") Or (Left(txtKiny.Text, 2) = "cy") Or (Left(txtKiny.Text, 2) = "gi") Then
ws.Cells(iRow, 7).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 2) = "in") Or (Left(txtKiny.Text, 3) = "inz") Or (Left(txtKiny.Text, 2) = "nz") Then
ws.Cells(iRow, 8).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "uru") Or (Left(txtKiny.Text, 3) = "urw") Or (Left(txtKiny.Text, 2) = "ru") Or (Left(txtKiny.Text, 2) = "rw") Then
ws.Cells(iRow, 9).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "aka") Or (Left(txtKiny.Text, 3) = "ak") Or (Left(txtKiny.Text, 3) = "aga") Or (Left(txtKiny.Text, 2) = "ka") Or (Left(txtKiny.Text, 2) = "k") Or (Left(txtKiny.Text, 2) = "ga") Then
ws.Cells(iRow, 10).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "utu") Or (Left(txtKiny.Text, 3) = "utw") Or (Left(txtKiny.Text, 3) = "udu") Or (Left(txtKiny.Text, 2) = "tu") Or (Left(txtKiny.Text, 2) = "tw") Or (Left(txtKiny.Text, 2) = "du") Then
ws.Cells(iRow, 11).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "ubu") Or (Left(txtKiny.Text, 3) = "ubw") Or (Left(txtKiny.Text, 2) = "bu") Or (Left(txtKiny.Text, 2) = "bw") Then
ws.Cells(iRow, 12).Value = Me.txtKiny.Value
End If
If (Left(txtKiny.Text, 3) = "uku") Or (Left(txtKiny.Text, 3) = "ukw") Or (Left(txtKiny.Text, 3) = "ugu") Or (Left(txtKiny.Text, 2) = "ku") Or (Left(txtKiny.Text, 2) = "kw") Or (Left(txtKiny.Text, 2) = "gu") Then
ws.Cells(iRow, 13).Value = Me.txtKiny.Value
End If
Me.txtKiny.Value = ""
Me.txtKiny.SetFocus
End Sub
Private Sub cmdClose_Click()
Unload Me
End Sub |
Partager