当值为空时,我想创建一个循环以在列N中粘贴“在线”。这可能吗?
答案 0 :(得分:1)
试试这段代码。我假设您知道N列中的最后一行,否则您将不得不将其更改为do-while循环
Sub LoopN()
Dim i As Long
Dim n As Long
n = cells(rows.count, "N").end(xlup).row
For i = 1 To n
If Cells(i, 14).Value = "" Then Cells(i, 14).Value = "online"
Next i
End Sub