Sub Button17_Click()
Dim Rws1 As Long, tbOK As String, tbLoi As String, tbao As String, tbHoanThanh As String
tbOK = "Xin m" & ChrW(7901) & "i nh" & ChrW(7853) & "p d" & ChrW(7919) & " li" & ChrW(7879) & "u " & ChrW(273) & ChrW(417) & "n thu" & ChrW(7889) & "c!"
tbLoi = "B" & ChrW(7841) & "n c" & ChrW(7847) & "n nh" & ChrW(7853) & "p s" & ChrW(7889) & " l" & ChrW(432) & ChrW(7907) & "ng " & ChrW(273) & ChrW(417) & "n thu" & ChrW(7889) & "c, gi" & ChrW(225) & " tr" & ChrW(7883) & " nh" & ChrW(7853) & "p v" & ChrW(224) & "o ph" & ChrW(7843) & "i l" & ChrW(224) & " s" & ChrW(7889) & " l" & ChrW(7899) & "n h" & ChrW(417) & "n 0."
tbHoanThanh = ChrW(272) & ChrW(227) & " ho" & ChrW(224) & "n th" & ChrW(224) & "nh !"
tbao = "Thông báo!"
With Sheets("Xuat thuoc le")
Rws1 = .Range("B65536").End(xlUp).Row
If Rws1 = 1 Then
' MsgBox "Hay nhap du lieu don thuoc"
Application.Assistant.DoAlert tbao, tbOK, msoAlertButtonOK, msoAlertIconInfo, msoAlertDefaultFirst, msoAlertCancelDefault, False
.Range("B" & Rws1 + 1).Select
ElseIf Application.CountA(.Range("B2:B" & Rws1)) <> Application.CountIf(.Range("D2:D" & Rws1), ">0") Then
' MsgBox "Hay nhap DU SO LUONG thuoc"
Application.Assistant.DoAlert tbao, tbLoi, msoAlertButtonOK, msoAlertIconCritical, msoAlertDefaultFirst, msoAlertCancelDefault, False
Else
' MsgBox "Da Hoan Thanh"
Application.Assistant.DoAlert tbao, tbHoanThanh, msoAlertButtonOK, msoAlertIconInfo, msoAlertDefaultFirst, msoAlertCancelDefault, False
End If
End With
End Sub