Rawland Hustle
Rawland Hustle

Reputation: 781

IF statement to ArrayFormula?

I have a formula in D3 that look like this:

=IF(B3="","",B3-B2)

How do I fill the whole column D (from D3) with that formula using ArrayFormula?

Upvotes: 0

Views: 49

Answers (2)

MattKing
MattKing

Reputation: 7773

=ARRAYFORMULA(IF(B3:B="",,B3:B-ARRAY_CONSTRAIN(B2:B,ROWS(B3:B),1)))

Upvotes: 2

a-burge
a-burge

Reputation: 1574

=ARRAYFORMULA(IF(B3:B501="","",B2:B500-B3:B501))

Upvotes: 0

Related Questions