PDA

View Full Version : Set default sort for a paricular column



sachin sachdeva
16 Nov 2010, 3:34 AM
hello sir i am new to extjs will u please tell me how could i set a default sort for my column my code is given below

{
header : "Size (KB)",
dataIndex : 'size',
resizable : false,
sortable : true,
width : 60
},
i want to set default order to desc is there any workaorund for that

JanVenekamp
16 Nov 2010, 4:29 AM
Sorting is done in the store. You can set the default sort with the sortInfo config: http://dev.sencha.com/deploy/dev/docs/?class=Ext.data.Store&member=sortInfo