when do you call CalcColumn()?
You havent quite grasped the concept which is where you are going wrong but thats why we are here :)
Are you using a strong typed dataset to get your data? You dont want to add the unbound column to the grid in a grid editor (this isnt an unbound grid column its an unbound datacolumn - there is a big difference in the two).
Wherever you get your dataset from... before you pass it to the grid to bind it, thats where you need to put those lines of code.
It will work, its just you arent calling it at the correct time (if at all).
So you need to
1. Get your dataset from the database
2. Add the unbound column with the expression to the datatable
3. Bind it to the grid.
If you have a strong typed dataset then you can add the column there and even set the expression there. IF not then you have to use those few lines of code.
Try and grasp this concept (unfortunately they are similar names so everyone gets confused in the beginning). You have a database which has tables and columns. You have an ado.net dataset which has tables and columns (these can map one to one but do not have to! thats very important.. it was done deliberately to give us more power... old ado before ado.net would not let us split the two). You have a grid that has columns. All columns are different entities and although you can map or bind them they can exist without each other.
Hope i might have cleared things up a wee bit