Problem with tableView height

Hello

I’ve been recently having trouble with controlling the height of the table view. You see in the example of the tableView the size of the tableView are small like this espicially when the code for height is set like this

for i = 1, 20 do     list:insertRow{         height = 72,         onRender = onRowRender,         listener = onRowTouch     } end  

Originally the rows are suppose to be like this when the code is like

for i = 1, 20 do     list:insertRow{         height = 72,         onRender = onRowRender,         listener = onRowTouch     } end  

So is why height tableview not working? This would make the height code useless since it does not make the height bigger. Also I’m using build 1095.

Hi sebitttas,

You do have some mixed code in there. Some properties are in the wrong place, as follows:

the onRender and listener properties belong in the tableview declaration:

 tableView = widget.newTableView { top = 32, width = 320, height = 400, listener = tableViewListener, onRowRender = onRowRender, onRowUpdate = onRowUpdate, onRowTouch = onRowTouch, }

the height property belongs indeed in the list:insertRow method call:

 -- Create 100 rows for i = 1, 100 do tableView:insertRow { isCategory = false, rowHeight = 80, } end

Did test this piece of quick code against 1095 and it’s working perfectly.

Hope this helps,

Alex

@alexf

Thank you very much for the help, and making it clear for me. I appreciate it a lot.

Hi sebitttas,

You do have some mixed code in there. Some properties are in the wrong place, as follows:

the onRender and listener properties belong in the tableview declaration:

 tableView = widget.newTableView { top = 32, width = 320, height = 400, listener = tableViewListener, onRowRender = onRowRender, onRowUpdate = onRowUpdate, onRowTouch = onRowTouch, }

the height property belongs indeed in the list:insertRow method call:

 -- Create 100 rows for i = 1, 100 do tableView:insertRow { isCategory = false, rowHeight = 80, } end

Did test this piece of quick code against 1095 and it’s working perfectly.

Hope this helps,

Alex

@alexf

Thank you very much for the help, and making it clear for me. I appreciate it a lot.