0

How to refresh page??

asked 2011-03-11 00:50:45 +0800

rohitwadke gravatar image rohitwadke
339 1 5

Hello everyone,

Can anybody tell me how to refresh page on click of button??

for Example e.g


<window>
<textbox />

<button>

</window>

on Click of above button it should clear all or refresh page..

Thanks in advance

delete flag offensive retag edit

4 Replies

Sort by ยป oldest newest

answered 2011-03-11 01:45:47 +0800

woodyki gravatar image woodyki
168

1. Every component object should be assigned id e.g. <textbox id="tb" />
2. handle onClick event of the button as below:

onClick="tb.setValue(null)"

Note: AJAX page should be refresh the components instead of the whole page.

link publish delete flag offensive edit

answered 2011-03-11 02:56:55 +0800

rohitwadke gravatar image rohitwadke
339 1 5

hey woodyki,
Thanks for reply.. but my be you didnt understand my question..

onClick="tb.setValue(null)" will not usefull if i have more then 20 textbox and listbox.. If i could refresh my page then i dont need to write onClick="tb.setValue(null)" for every button..

Thanks
Rohit

link publish delete flag offensive edit

answered 2011-03-11 03:07:04 +0800

woodyki gravatar image woodyki
168

updated 2011-03-11 03:12:09 +0800

It is possible if every component has data binding with EL or ZScript in the ZUML.
Every component will refresh when the browser refresh the page.
That is just like this forum list.

The onClick event can call the URL to refresh the page itself.

onClick="Executions.sendRedirect(URL)"

link publish delete flag offensive edit

answered 2015-12-30 11:22:40 +0800

dmitrakov gravatar image dmitrakov
1

You can use Executions.sendRedirect(null);

link publish delete flag offensive edit
Your reply
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

Follow

RSS

Stats

Asked: 2011-03-11 00:50:45 +0800

Seen: 1,493 times

Last updated: Dec 30 '15

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