DataGrid
The DataGrid control is so powerful that it hardly needs any explanation. It not only displays data, it provides methods for letting the user insert, update, and delete records. To modify a value, simply click on the grid cell and type the new value. To delete a record, click to the left of its grid row to select the row and then press Delete. To create a new record, click on any field in the grid’s bottommost row (marked with an asterisk) and start typing.
All these features mean you don’t need to add much code to make the DataGrid work. Because the grid displays all rows and columns at once, you don’t even need to add any kind of navigation method. The user just points, clicks, and types. Figure 8.16 shows program ContactsGrid displaying ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access