Loading...
Important Notice - Forums is archived

To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.

Product icon
TUTORIAL

Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.

TreeTable and beans

Enkara Dura
5 years ago Jun 02, 2016 12:59pm
Tom Rauchenwald
5 years ago Jun 08, 2016 6:39am

I assume the line about adding objects should read

addItem(new Object[]{"nameX", "surnameX"}, "itemid");

i.e., you're adding the cells for a row as Array of Objects.
If you want to use beans, you need to use a container that supports them (BeanItemContainer for example).
Unfortunately BeanItemContainer doesn't support hierarchical components.
See this thread for some suggestions: https://vaadin.com/forum#!/thread/1928897