Dolibarr extrafields (rows) calculation formula

I added extra fields to the lines in the shipping module, I want the D (D = (A*B)+C) value to be calculated and added as I tried to show in the picture. I tried to do research on the calculated fields, but I could not come to a conclusion. I was able to add it via card.php with an SQL query, but when I make changes to the A, B and C values, the D value remains in the first calculation and does not change.

Can you please help me on this matter.