Creating Pages Manually [closed]

asked 2018-05-08 19:33:29 +0800

jgunning gravatar image jgunning
33 2

Hi there,

Does anybody if it's possible to attach a Page to a Desktop manually in ZK I need to do this because I am loading zul files using the mechanisms outlined here:

ZK Developer's Reference/UI Composing/ZUML/Load ZUML in Java

and it's causing problems when I try to add context menus to different parts of my application.



delete flag offensive retag edit

The question has been closed for the following reason "the question is answered, right answer was accepted" by cor3000
close date 2018-05-21 09:37:44

2 Answers

Sort by ยป oldest newest most voted

answered 2018-05-17 11:07:56 +0800

cor3000 gravatar image cor3000
3922 1 7
ZK Team

updated 2018-05-17 11:08:24 +0800

I made your zkfiddle runnable...

  • I simply inlined the zul code into a String
  • and I removed the unnecessarily hard coded id at the contextMenu

(see -> http://www.zkfiddle.org/sample/ha01no/20-Create-Page-Manually)

From my side it just seems to work as usual.

Can you please point out what your problem is?

link publish delete flag offensive edit


Hi there, That works! Thanks for that. Greatly appreciated.:-) Should have spotted that one myself. Got stuck not being able to see the forest for the trees!. J.

jgunning ( 2018-05-21 00:12:26 +0800 )edit

thanks for getting back

cor3000 ( 2018-05-21 09:37:31 +0800 )edit

answered 2018-05-08 19:39:39 +0800

cor3000 gravatar image cor3000
3922 1 7
ZK Team

Calling createComponents() usually works and is used internally ZK in many places.

Can you provide a code example illustrating your problem (preferably on http://zkfiddle.org/)? (I increased your Karma so you can post links)


link publish delete flag offensive edit


Hi there,

Thanks for getting back to me. I posted some example code at: http://www.zkfiddle.org/sample/ha01no/8-Create-Page-Manually#source-6

However, I keep getting a ClassNotFoundException: zkdebugjg.ApplicationController. I guess I'm not sure I'm setting it up right in zkfiddle?



jgunning ( 2018-05-14 19:41:34 +0800 )edit

in zkfiddle you should use the full package including the pkg$. prefix

cor3000 ( 2018-05-16 14:04:08 +0800 )edit

OK. Thx. I've moved it along. Not getting a NullPointerException. Sorry if it's a noobie question but how do I put the zul file in the right package in zkfiddle?

jgunning ( 2018-05-17 04:15:12 +0800 )edit

I don't now where zkfiddle puts the temp files myself... I think it's easier to just read the string data from memory (any inputstream is an inputstream) e.g. new ByteArrayInputStream(str.getBytes("zul code"))

cor3000 ( 2018-05-17 10:15:26 +0800 )edit

Question tools

1 follower



Asked: 2018-05-08 19:33:29 +0800

Seen: 8 times

Last updated: May 17