Is there an example of binding the WebHierarchicalDataGrid to a Dataset at runtime?
The dataset would contain multiple tables with relations.
Thanks for any help.
Hello,
This sample shows how to bind the grid to a dataset. I know it does not show how the data set was actually created, but that should not be a problem, I'd imagine.
Is there any particular problem you are facing?
Thanks. I've seen that sample.
I've bound the dataset to the grid, but I'm getting an error alert when I try to expand a parent row:
"Runtime Exception: No child grid script descriptors are available!"
I'm manually setting the primary key on each table in the dataset. I'm then setting the relations in the dataset. The grid is set to autogenerate columns and bands. InitialDataBindDepth is set to 0. Is there something else I'm missing?
To fix the previous error, I needed to set the dataset to rebind after each postback.
But now I am getting a script error each time on the second attempt to expand a parent row. The first expansion attempt always works, on any row. But the second expansion attempt (parent row) always fails with the error:
"Microsoft JScript runtime error: Sys.ArgumentException: Cannot deserialize. The data does not correspond to valid JSON. Parameter name: data"
Can you post your code for generating your DataSet here? Thanks.
Alex,
I was able to determine the cause of the error was the format of a date column in the child band. After changing the format to 'mm/dd/yyyy' the issue cleared up.
Thanks