It's more professional to fix the formulas so they don't return #NA.

But, if you must have the errors, here are two ARRAY FORMULA options.
Note: Commit array formulas with CTRL+SHIFT+ENTER, instead of just ENTER.

Option_1:
=SUMPRODUCT(IF(ISTEXT(P8:BX182),(LEFT(P8:BX182,1)="H")*MID(P8:BX182,3,255)))

Option_2:
=SUMPRODUCT(IF(NOT(ISERROR(P8:BX182)),(LEFT(P8:BX182,1)="H")*MID(P8:BX182,3,255)))
I hope that helps.