Skip to main content
1-Visitor
August 18, 2014
Solved

How to add checkbox "select rows" in customized table.

  • August 18, 2014
  • 1 reply
  • 1933 views

Friends,

I need add checkbox "select rows" in my customized table:

checkbox.jpg

The class that I'm moving is as follows:

@Override

public ComponentConfig buildComponentConfig(ComponentParams componentParams)

throws WTException {

ComponentConfigFactory factory = getComponentConfigFactory();

TableConfig table = factory.newTableConfig();

table.setLabel("Lista dos Fornecedores");

table.setView("/../../netmarkets/jsp/t3827/tableFornecedor.jsp");

table.addComponent(factory.newColumnConfig("number", true));

table.addComponent(factory.newColumnConfig("name", true));

table.setMenubarName ("forntablemenubar");

return table;

Can you help me?

Felipe Oliveira.

Best answer by VasiliyRepecki

table.setSelectable(true);

1 reply

1-Visitor
August 19, 2014

table.setSelectable(true);

1-Visitor
August 19, 2014

Thank you Vasiliy,

Besides this, I also added the counter:


table.setShowCount(true);

It was perfect .

Felipe.