Function Generating HTML Problem

Function Generating HTML Problem

Good day, Im trying to edit a function that create a HTML page, but when I change something I need and I try to save, it shows me the following Error,

Error at line number : 28 
'Proyecto' is a lookup field and child fields cannot be accessed

The issue is that I am editing other line, and the function is working already with that existing code. If I open the function and click save script with any modification always error appears.

Support is available in the application and the function name is AvanceDiario.generateAvanceDiario.


Best Regards,