How To Add Dynamic Column in Flexi Grid

In this tutorial i will describe how to add dynamic column in flexi grid normally we are working flexi grid with fixed column but some times we need to add dynamic column with flexigrid, that times we need to modify logic as per requirement.For this we need to get column value in array and convert to json object.

Also Checkout other tutorials of flexi grid,

There are following steps to needed for dynamic columns.

Step 1: We will get dynamic column and assign into array.

Step 2: Now we will set above array to the flexigrid.

The main concern in this tutorial, the fields key will be same as resulted data based on controller action, otherwise the flexi grid would be not show.

Step 3: Now we will bind grid with controller action:

I hope, Its help you to add dynamic column into flexigrid table.