Activate RETURN key only if certains conditions are met?

I tried the long press setup, as per this thread

and I activated thr HUD to see if triggered. So the shortcut is trigerred, but nothing happen ?

I tried the Key sequence, and, instead of pressing enter the RETURN key assigned action has the effect of delecting the last 2 letters I wrote...

There is something I dont get...