I have given your code a try. For some reasons this is returning null Label lblPlanStartDate = (Label)item.FindControl("plannedstartdate");
and therefore blowing up at stringvaluestartdate = lblPlanStartDate.Text;
Infact I have to change the code to use GridCommandItem because the your code was not reaching GridDataItem
The GridTableView object has an Items property that contains all the data rows in the table view. Each row is represented by a GridDataItem or GridEditFormItem object, depending on whether the row is an edit form. Since you are trying to access values of columns, you should access through GridDataItem. We use GridCommandItem, when we want to access controls inside the CommandItem, that is displayed on top or at the bottom of the each GridTableView base on the settings of CommandItemDisplay property. The above code works fine at my end, can you please provide your full code snippet to identify the issue.