Try changing the formula in Column 8 to return a 0 instead of a blank if error occurs...
=IF(ISERROR(IF($E$8>0,$E$8,IF(INDEX(Readings!$E$12:$GT$500,MATCH($E$4,Readings!$B$12:$B$500,0),MATCH(Grazing[[#This Row],[Column2]],Readings!$E$11:$GT$11,0))<=0,$E$7,(INDEX(Readings!$E$12:$GT$500,MATCH($E$4,Readings!$B$12:$B$15,0),MATCH(Grazing[[#This Row],[Column2]],Readings!$E$11:$GT$11,0)))))),0,IF($E$8>0,$E$8,IF(INDEX(Readings!$E$12:$GT$15,MATCH($E$4,Readings!$B$12:$B$15,0),MATCH(Grazing[[#This Row],[Column2]],Readings!$E$11:$GT$11,0))<=0,$E$7,(INDEX(Readings!$E$12:$GT$15,MATCH($E$4,Readings!$B$12:$B$500,0),MATCH(Grazing[[#This Row],[Column2]],Readings!$E$11:$GT$11,0))))))
also, if you are using Excel2007 or later, you can shorten it to:
=IFERROR(IF($E$8>0,$E$8,IF(INDEX(Readings!$E$12:$GT$500,MATCH($E$4,Readings!$B$12:$B$500,0),MATCH(Grazing[[#This Row],[Column2]],Readings!$E$11:$GT$11,0))<=0,$E$7,(INDEX(Readings!$E$12:$GT$500,MATCH($E$4,Readings!$B$12:$B$15,0),MATCH(Grazing[[#This Row],[Column2]],Readings!$E$11:$GT$11,0))))),0)
You can also fix the formula in Column 5 to give blank with Column 7 is blank instead of error:
=IF(Grazing[[#This Row],[Column7]]="","",IF($I$14>Grazing[[#This Row],[Column11]],$E$13+(Grazing[[#This Row],[Column7]]*Grazing[[#This Row],[Column8]]),IF(Grazing[[#This Row],[Column11]]=$I$14,$E$13,IF((INDEX(Readings!$E$12:$GT$500,MATCH(Grazings!$E$4,Readings!$B$12:$B$500,0),MATCH(Grazing[[#This Row],[Column1]],Readings!$E$11:$GT$11,0)))+(($I$14-$E$4)*Grazing[[#This Row],[Column8]])<500,0,(INDEX(Readings!$E$12:$GT$500,MATCH(Grazings!$E$4,Readings!$B$12:$B$500,0),MATCH(Grazing[[#This Row],[Column1]],Readings!$E$11:$GT$11,0)))+(($I$14-$E$4)*Grazing[[#This Row],[Column8]])))))
Bookmarks