0

Dinamically included pages

asked 2006-01-20 13:48:24 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3532692

By: matteo_barbieri

I've problems accessing pages dinamically included.
For example, if I have:

<include src='/page.zul' />

I can access it in the window code by calling

this.getDesktop().getPage('page')

but if do this:

<include id='inc' />

and in the code

this.getFellow('inc').setSrc('/page.zul');
this.getDesktop().getPage('page');

It doesn't find the page.

delete flag offensive retag edit

4 Replies

Sort by ยป oldest newest

answered 2006-01-21 05:13:17 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3534036

By: tomyeh

The include component includes the specified URL in the redering phase (see User Guide). In other words, when your second statement executes, the page is not created yet.

To create components immediately, use Executions.createComponents. They are plenty of ways to create components by loading from another ZUML page, from direct content...

link publish delete flag offensive edit

answered 2006-01-23 11:51:37 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3536301

By: matteo_barbieri

I would prefere to use Include and easily change src to switch between View-Edit pages.

Is there something like

myInclude.setSrc('page.zul');
myInclude.updateSrc();

?

Bye

link publish delete flag offensive edit

answered 2006-01-23 12:41:46 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3536360

By: tomyeh

No.

The include component could include anything, and we know it only in the rendering phase. For better performance, the rendering phase must be the last step (such that we could optimize redudant update).

Maybe we could have another component that include only the ZUML pages, such that it could use createComponents to do the job. But it adds confusion to what components to use.

link publish delete flag offensive edit

answered 2006-01-23 14:34:42 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3536534

By: matteo_barbieri

> Maybe we could have another component that include only the ZUML
> pages,

I've wrote such a component (IncludeZul).

Thank you.

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: 2006-01-20 13:48:24 +0800

Seen: 564 times

Last updated: Jan 23 '06

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