|How to set the number of visible rows in Table? [message #521315]
||Wed, 17 March 2010 09:04
Registered: March 2010
I have a table:
Table table = new Table(myComposite, SWT.MULTI);
table.setLayoutData(new GridData(SWT.FILL, SWT.FILL, false, false);
TableColumn tableColumn = new TableColumn(table, SWT.LEAD);
tableColumn = new TableColumn(table, SWT.LEAD);
viewer = new TableViewer(table);
How can I set the number of displayed rows to i.e. 3, independently from number of rows filled by user data?
I tried to do it in two ways - using method setItemCount() on Table object and on TableViewer object (see commented lines in the code above). The problem is, that while performing the line:
an exception appears:
AssertionFailedException: null argument
which disappears when I comment out the setItemCount() call....
Is this method bugged or am I using it in wrong way?
Whether it's strange behavior and I'd like to understand it, most important to me is to know, how can I actually set the number of displayed rows?
[Updated on: Tue, 23 March 2010 08:38]
Report message to a moderator
Powered by FUDForum
. Page generated in 0.02282 seconds