echo event in ZK - long operations

asked 2015-09-08 14:06:55 +0800

mayuranjan gravatar image mayuranjan
1 1

updated 2015-09-09 04:36:16 +0800


I am trying to implement the below example

books.zkoss.org/wiki/ZKDeveloper'sReference/UIPatterns/LongOperations/ UseEchoEvents

in this example there is "doLongOperation(); //take long to execute". How can i implement this?

The Code is as below:

<window id="w" width="200px" title="Test echoEvent" border="normal">
  <attribute name="onLater">
  doLongOperation(); //take long to execute
  Clients.clearBusy(); //remove the busy message

  <button label="Echo Event">
  <attribute name="onClick">
  Clients.showBusy("Execute..."); //show a busy message to user
  Events.echoEvent("onLater", w, null); //echo an event back 

And i am using the "doLongOperation()" method in vm. But this is not working.

delete flag offensive retag edit


can you post what you have already?

chillworld ( 2015-09-08 17:24:20 +0800 )edit

i have updated it in the question.

mayuranjan ( 2015-09-09 04:32:53 +0800 )edit

2 Answers

Sort by ยป oldest newest most voted

answered 2015-09-13 16:44:29 +0800

Darksu gravatar image Darksu
1991 1 4

Hello mayuranjan,

Please check the code at the following fiddle (there is an example there):


Best Regards,


link publish delete flag offensive edit

answered 2015-09-18 05:01:21 +0800

cor3000 gravatar image cor3000
4952 2 7
ZK Team


if you really want to work with echo events it's easier to implement the long operation in a java composer. (Doing this inside the zul file is not very performant)

here an example:


link publish delete flag offensive edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

1 follower



Asked: 2015-09-08 14:06:55 +0800

Seen: 86 times

Last updated: Sep 18 '15

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More