cancel
Showing results for 
Search instead for 
Did you mean: 

sortState Property

Former Member
0 Kudos

Hi All

I have been trying to use the sortState property to get the Table to come up pre-sorted based on a given column.

In the View controller I have set the property of the given table field to 'Down'.

But this doesnot seem to do anything ?

Is this not working or did I miss something ??

Regards

Aju Paul

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

The "sortState" property is only used to store the current sort state of a table column in the view controller context.

To sort a table column, you have to call the IWDNode.sortElements(Comparator) method on the data source node.

Armin

Former Member
0 Kudos

Hi Armin

Thanks for your response, we have use the sortState in the view controller context. Should the table then appear sorted in the relavant view . In our case, that isnt happening.

Any further thoughts, we are planning to try out approach number 2.

Aju

Former Member
0 Kudos

Please read my answer again.

You have to do both, bind the sortState property to a context attribute and call the sortElements(Comparator) method.

Binding the sortState alone does not sort the table.

Armin

Former Member
0 Kudos

Hi Armin,

I have a requirement in which One of the TableColumn is sortable and records are getting sorted also.

But upon selection of another dropdown present in the same UI I have to make this column un-sortable.

For this I am using:

 

column.setSortState(WDTableColumnSortDirection.NOT_SORTABLE);

But this does not have any impact.

I am trying this in nw730 codeline.

Regards,

Manoj

Former Member
0 Kudos

Hi,

Anybody knows what's the solution for the above problem?

No replies yet.

Regards,

Manoj

Edited by: Manoj on Apr 29, 2010 7:37 PM