Tool building - datagrid with checkbox column
Spent a stack of time trying to teach myself component building tonight. I've started building a component that is derived from DataGrid and binds some additional properties.
One of the properties - AllowMultiSelect - determines whether or not the grid displays a column of checkboxes or not. The checkbox column enables the user to select multiple items in the grid which are then exposed on postback via another property named "SelectedItems".
You can view the source code for the component at my online forum:
Forum Url: http://www.markitup.com/forum/forum.html
Post title: Tool building - datagrid with checkbox column
I initially got the inspiration for this control while reading Dino Esposito's book:
Building Web Solutions with ASP .NET and ADO .NET View at Amazon
I never actually tried Dino's sample so I'm not sure how good it is, but, in my conversion to VB code things started to go screwy. For example, when toggling between design view and source view the grid would add a new checkbox column each time. I got around this by tracking the state of the control in an attribute - it's a bit mungy :-)
<shrug /> Perhaps I'll tidy it up tomorrow!