Hi @EduLibre - I am not totally certain, but think you might be trying to operate in a mode that is not supported. Per my understanding, I do not think you can load/run 'when Flag clicked' programs onto an Arduino board. I think this program variant can only be used with one of the MakeBlock boards - Orion, mCore, etc. (The documentation is a bit confusing as I do recall seeing one part of a video that appeared to suggest you could load onto an Arduino UNO, but I do not think this is the case).
I've used Arduino mode to load 'Arduino Programs' and 'mBot Programs (see below) onto an UNO. I tried your 'when Flag clicked' example though and got the same results you did .. but again, I'm not sure if this mode is supposed to work.
(This works fine .. )
(I could be wrong or misunderstanding something myself here .. if so, hopefully someone will jump in and set things straight).
Just curious - is there a particular reason you're trying to get that 'Flag clicked' version to work?