sub test()myrow=Range("A65536").End(xlUp).Rowfor i=myrow to 1 step -1 if range("A" & myrow )="X" then Range("A" & i & ":A" & myrow).ClearContents end ifnextend sub