Assuming we refer to the first program, the ENDIF it there at the end.

On the snippets it is missing, but I doubt that this can compile anyway.

Ioannis