Mình mới tìm hiểu VBA được 1 ngày. Nhờ các bạn sửa giúp mình.
Khi chạy code này thì bị báo lỗi "object doesnd't support this property or method"
Mã:
Sub thunghiem()
Dim t As Variant
For x = 1 To 10
For y = 1 To 10
Set t = Worksheets("sheet1").cell(x, 1) + Worksheets("sheet2").cell(y, 1)
If t > 35 Then
Worksheets("sheet2").cell(y, 2).Value = t
End If
Next y
Next x
End Sub