Calc formula fields Err:504 (Protected view?)

I am opening a work file created in Excel in Calc, If I open the file in Excel, I get an error in same fields: #VALUE! with the warning message at the top indicating file is in Protected View. When I click Enable Editing, the problem resolves. How can I do the equivalent in Calc? I do not see a similar message. I tried to toggle Edit-Edit Mode and click Enable Protection, but it does not affect it. I am getting Err:504 in the calculated fields. the field that meets criteria works, the other 2 fields do not, and the 4th field is a SUM of the previous 2 fields.
The formula is =MAX(0, IF(AND($E$39>6.99, $E$39<11), $E$38- 5000, "0")). All 3 calculating cells have the same formula (line 42,43,44), just the parameters change. The Total field (line 45) is failing due to garbage in the preceding cells. Each individual cell calculates properly if criteria is met, it seems to fail on when the result is outside the parameters and the formula should return “0”… it seems that the formula is not being triggered by default, so the total always displays Err:504. This is very annoying and I’ve had to dig out an old computer that has MS Excel to process this. I work for a small company that does not have an IT dept, their solution would be to tell me to get MS Office, I don’t think they would send me an unprotected file (if that is even the issue). I am using Windows 11 laptop which I just purchased in July, installed the previous version of LibreOffice, then did the upgrade when if came out. I do not believe I have opened this particular file that has these formulas in Calc before, so I can’t say if I had this issue before. I have opened other Excel sheets that are in Protected Mode (do not get that msg in Calc, Edit Mode is checked by default), that only have SUM calculations, and there is no issue and no error code. Any suggestions?

In your formula, if the condition is FALSE, then the result is “0” (as a text). Using the MAX function on a text returns the ERR:504 error.

So correct the formulas and replace “0” by 0.

2 Likes

And if you placed the cell cursor on that Err:504 reading cell then the status bar displayed “Error in parameter list”. See also Error Codes in LibreOffice Calc.