PDA

View Full Version : How to keep hideable column to stay hide



hudi1
6 Jun 2013, 12:45 AM
Hi,

I have some column in my grid panel hide:


xtype : 'gridpanel',
itemId : 'contact_list',
header : false,
title : 'Contact List',
store : me.initialConfig.store,
columns : [ {
xtype : 'numbercolumn',
hidden : true,
dataIndex : 'id',
text : 'Id',
format : '0'
}

how to remove hide/show function in all columns menu ? I dont want to display columns which I select hide

Farish
6 Jun 2013, 3:40 AM
if you are not using any options in the header menu, then you can set menuDisabled: true on the grid's columns. this will cause the menu not to appear at all. I dont know how to hide only the column hide/show options.

hudi1
6 Jun 2013, 3:50 AM
I dont want to disable menu because columns which are visible I can hide but colums which are hide in init I dont want to show

slemmon
6 Jun 2013, 2:59 PM
I believe hideable: false is what you're looking for:
http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.grid.column.Column-cfg-hideable

hudi1
6 Jun 2013, 10:24 PM
ok thx a lot it works

slemmon
7 Jun 2013, 12:58 PM
Excellent. So, this thread can be marked as Answered?