Got a ws, were I want to fill inn value "n/a" in blank cells.
The ws only holds columns from A to M, but when I run the code below it fills in "n/a" in row 1, cells N and as far to the right as it is allowed before I stop the vba manually...
What is wrong With this code?
And if there is something to the formatting of row 1 (headers), how can I change the code so that it starts from row 2?
And if anyone can fill in how to use range columns A:M + Down to last row, I can even try this out...
The ws only holds columns from A to M, but when I run the code below it fills in "n/a" in row 1, cells N and as far to the right as it is allowed before I stop the vba manually...
What is wrong With this code?
And if there is something to the formatting of row 1 (headers), how can I change the code so that it starts from row 2?
And if anyone can fill in how to use range columns A:M + Down to last row, I can even try this out...
Code:
For Each cell In Range(ActiveCell, ActiveCell.End(xlDown).End(xlToRight))
If IsEmpty(cell) Then
cell.Value = "n/a"
cell.HorizontalAlignment = xlRight
End If
Next
Last edited: