I had the same problem.
Oddly enough, the DataGrid will not have this problem, it will allow you to access data from hidden columns, even if it does not even display them on the client, as it still adds information about hidden columns to the ViewState.
GridView, on the other hand, simply ignores hidden fields, even if the EnableViewState property is set to true. The only way is to leave there information to hide with the style, for example display: none ;.
Unfortunately, I liked the behavior of the DataGrid, but the GridView has other advantages.
source share