|
|
Re: Pagination control with Tableviewer [message #79298 is a reply to message #79224] |
Wed, 26 March 2008 16:39 |
Eclipse User |
|
|
|
Originally posted by: rherrmann.innoopract.com
Hi Arpit,
I tried to reproduce what you described, but all worked as expected.
Could you provide some standalone code that reproduces the problem?
Cheers,
Rüdiger
Arpit Desai wrote:
> Arpit Desai wrote:
>> Hi folks,
>>
>> I am looking to create a componenet using tableviewer which will have
>> pagination controls and also buttons to export the data displayed in
>> the table as a csv/excel/html file.
>>
>> I am using the SWT.Virtual style for creating the viewer and hence the
>> data is loaded on need per basis. However, how do I provide pagination
>> control?
>>
>> I tried tableviewer.getTable().setTopIndex(0) and on clicking NEXT I
>> set it to tableviewer.getTable().setTopIndex(10). But the data does
>> not refresh in the table.
>>
>> What am I missing? Any Ideas ...
>>
>> Thanks,
>>
>> Arpit
>
> Somehow I endup getting run time error as follows:
>
> Could not evaluate javascript response:
>
> 'undefined' is null or not an object
>
> org.eclipse.swt.EventUtil.suspendEventHandling();var req =
> org.eclipse.swt.Request.getInstance();req.setRequestCounter(
>
> What I am doing is as follows:
>
> btNext.addSelectionListener(new SelectionAdapter(){
> @Override
> public void widgetSelected(SelectionEvent e) {
> System.out.println("TopIndex:" +
> enclosureViewer.getTable().getTopIndex());
> enclosureViewer.getTable().setTopIndex(index + incr);
> System.out.println("TopIndex after next:" +
> enclosureViewer.getTable().getTopIndex());
> enclosureViewer.refresh();
> }
> });
>
>
> Is this a bug ?
|
|
|
|
Powered by
FUDForum. Page generated in 0.01870 seconds