This fiddle : http://zkfiddle.org/sample/37pokiu/2-onLaterPostNoError#source-2.
Events.echoEvent is only triggered when you doubleClick on the button.
When you change the onClick$btn(Event e) to this :
public void onClick$btn(Event e) throws InterruptedException
{ // Events.echoEvent("onLater", mainWindow, null); sendError() }It work on a single click.