New Control: EmptyDataGrid

With all the talk yesterday about what to do when a DataGrid receives no data, and how v2.0 of ASP.NET should handle this, I decided to sit down and see if I could implement this as a custom server control.

Well after a few short hours, I've got a working EmptyDataGrid that inherits and extends the current DataGrid. It adds 2 new properties, EmptyDataTemplate and EmptyDataStyle. The behavior for displaying the datagrid is different depending on your data source, however. For example, if you use a DataSet/DataTable, you will see the columns at the top, and the EmptyDataTemplate as a row beneath that. However, if you use a DataReader as the data source, then you will only see the EmptyDataTemplate displayed.

If you're extremely excited to see this in action, let me know and I can post a sample. However, this control will not be released until I release v1.9 of my control set. Though, if you're in dire need, I can create a custom assembly with only this control, just let me know.  A custom assembly has been put together, however you need to contact me to receive it.  Note that this is not an official release of the control.

1 Comment

Comments have been disabled for this content.