Chào anh chị
Cho em hỏi đoạn mã sau
Sub Tinhgio()
Dim I As Long, J As Long
For I = 8 To 2000
If Cells(I, 3).Value = "ca ngay" Or Cells(I, 3) = "hanh chinh" Then
Cells(I, 19).Value = Cells(I, 15).Value - Cells(I, 11).Value
ElseIf Cells(I, 11).Value < Cells(I, 15).Value Then
Cells(I, 19).Value = Cells(I, 15).Value - Cells(I, 11).Value
End If
Next I
End Sub
Đoạn mã này có gì sai mà em không chạy được?
Cho em hỏi đoạn mã sau
Sub Tinhgio()
Dim I As Long, J As Long
For I = 8 To 2000
If Cells(I, 3).Value = "ca ngay" Or Cells(I, 3) = "hanh chinh" Then
Cells(I, 19).Value = Cells(I, 15).Value - Cells(I, 11).Value
ElseIf Cells(I, 11).Value < Cells(I, 15).Value Then
Cells(I, 19).Value = Cells(I, 15).Value - Cells(I, 11).Value
End If
Next I
End Sub
Đoạn mã này có gì sai mà em không chạy được?
Lần chỉnh sửa cuối: