Is it possible to modify the SqlDataSource of a RadGrid, before it gets bound to the grid?
In my example I have query that is returning sets of data with the following column names.
Parameter1Title
Parameter1Value
Parameter2Title
Parameter2Value
Parameter3Title
Parameter3Value
What I need to do is sort of normalize this set into just two columns that contains only the ones that have a value.
For example, imagine the returned set contains these values.
Parameter1Title "Age"
Parameter1Value "45"
Parameter2Title null
Parameter2Value null
Parameter3Title "Color"
Parameter3Value "Blue"
From this I need to created an SqlDataSource that holds the following info for the grid
Parameter Value
"Age" "45"
"Color" "Blue"
Where the 2nd parameter set was ignored as it had no value.
Note also, this Parameter grid is a child grid to grid called Attributes. That is, it's SqlDataSource is fed the AttributeID as the rows on the Attribute grid as clicked.
Where would I make this change? That is, intercept before the data is bound to the grid? Also, am I better off creating a new DataSet to bind to the grid? Is that possible with the RadGrid?