문제

I have a SWT Table inside a coposite, and i have used TableColumnLayout for dynamically resizing the table columns.

I get the following error while trying to launch the jface dialog which contains the table.

org.eclipse.core.runtime.AssertionFailedException: assertion failed: Unknown column layout data

This is the corresponding code used :

TableColumnLayout layout = new TableColumnLayout();
composite.setLayout(layout);

layout.setColumnData(column1, new ColumnWeightData(30));
layout.setColumnData(column2, new ColumnWeightData(30));
layout.setColumnData(column3, new ColumnWeightData(30));
layout.setColumnData(column4, new ColumnWeightData(30));
layout.setColumnData(column5, new ColumnWeightData(30));

Can anyone let me know What is causing me the error ?

도움이 되었습니까?

해결책

The assertion is thrown if the column data is not an instance of ColumnWeightData or ColumnPixelData for all the defined columns. So my guess is that you have not set the column data for one of your columns.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top