Listbox - ComponentDefinition - store/load at runtime

asked 2020-01-28 19:37:55 +0800

Tedatzs gravatar image Tedatzs
3 2


to store the different user listbox views (visible, col order, widhts) is it possible to store different component definition (via listbox.getDefiniton()) to load/render them to the listbox with listitems at runtime?


delete flag offensive retag edit

1 Answer

Sort by » oldest newest most voted

answered 2020-01-31 14:44:27 +0800

MDuchemin gravatar image MDuchemin
1561 1 5
ZK Team

Hi Markus,

Component definition contains things like component properties, molds, classes used etc. It's not a snapshot of a component's state, so you won't be able to recreate a component from scratch with just that.

If you are using a composer or a viewModel, the easiest solution is to store all relevant state information in this class, receive user actions updates (to update the state in the viewModel or the composer) and then apply it to the next component on which you want to duplicate the setting. If this is a common case, you may even want to make you own ListboxState class, with getters and setters to hold these state information.

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




Asked: 2020-01-28 19:37:55 +0800

Seen: 6 times

Last updated: Jan 31

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