VBA newb here. I’m using a loop to check the contents of cell (n, 26) and also to create an index “o”. I then check whether cell (o, 29) is empty, and print out some text to column 36 based on two conditions being met. When I click to compile, I get “Run-time error ‘1004’: Application-defined or object-defined error”. Can anyone see the issue?
Sub codeOutcome()
Dim n As Integer, o As Integer
For n = 2 To 56
o = Cells(n, 2).Value
If Cells(n, 26).Value = "test text" And Cells(o, 29).Value = " " Then Cells(n, 36).Value = "test text"
Next n
End Sub
5