"Does this do the same function as your formula?"
Wouldn't expect it to, as my changes are two additions to the formula presented in your initial post, and your edits include both additions to that formula, a change to the relationship between the original two IF statements, and changes to some cell references in those IFs.
Here's the original, with my revision above it and yours below. Changes are in bold.
revision B: IF(L4≥I4,I4×H4,0)+IF(L4≤G4,−G4×F4,0)
original: IF(L4≥I4,I4×H4) +IF(L4≤G4,−G4×F4)
revision W: IF(L4=0,0+0,IF(L4≥J4,I4×J4 , IF(L4≤H4,−H4×G4,0+0)))
Why "0+0"? "0" gives the same result and skips the calculation of 0+0.
The initial formula, and revision B, have two independent IF statements. Both are evaluated each time the formula is run, and the results are added. Both these formulas give the same numerical results for the data provided in my example. The original presents a warning when either IF presents a FALSE result.
revision W adds an IF to test for 0 (or 'no entry') in L4, and returns zero if the test result i TRUE.
The original omits this test. 0 in L4 results in the formula returning the product of the contents of G4 and F4.
It appears the table has been edited by moving column K to a new location between E and F (now G).
revision W also changes the relationship between the IF statements.
In the original, each is independent, and each calculates every time the formula is run.
In the revision, the three are nested; the second is called only if the first's condition returns FALSE, the third is called only if the second's condition (also) returns FALSE, The formula will do only one of the root calculations: 0+0, I4*J4, H4*G4, or 0+0, exiting after the first TRUE encountered, or after the final FALSE if there are no TRUEs.