w2grid.getColumn

Finds the column and returns its object or index in columns array.
getColumn([field], [returnIndex])
field string, optional field name of the column
returnIndex boolean, optional indicates if return a column or its index in columns array
Returns object, integer or null.

Description

The column is identified by the .field property, which is a required property for each column object. The method loops through the .columns array to find the column object.
If called w/o parameters, it will return array of column names.
If you have grid defined in the following way: You can get the column:

User Comments

comments powered by Disqus