I have a receiving log spreadsheet where if an item needs a certain type of inspection (Y or N) a log number will be assigned in another cell. The column with the log numbers needs to take the next consecutive number in a series. Here is what I have:
A B AA
1 Y 101 101
2 N N/A 102
3 Y 102 103
4 104
5 105

The formula I have in B1 is =IF(A1=”N”,”N/A”,AA1)
Two questions:
1)When referencing column AA in the IF statement, the result in column B will return only the cell value related to the given row. Is there a way to have excel automatically sequence based on this need?
2) If I copy the formula in B1 down column B so it automatically assigns a number once there is data in column A, when the cell is blank it still returns the value associated to the row #, I need it to be blank.

Thanks in advance!