hello,
Can anyone tell me the difference between DataGrid(not GridView) and Grid controls in wpf?
Thanks
hello,
Can anyone tell me the difference between DataGrid(not GridView) and Grid controls in wpf?
Thanks
A Grid
is a control for laying out other controls on the form (or page).
A DataGrid
is a control for displaying tabular data as read from a database for example.
You can think of the Grid as a combination of the Windows Forms background layout and a spreadsheet (in that you can have rows and columns) into which you can add controls and position them.
The Grid view is a View element that can be used in a ListView control to display data from database, XML or even CLR objects, in columns and rows with column headers and row indicators, similar to (but not exactly like) the DataGrid control in Windows Forms. GridView is only really usable as part of a ListView AFAIK.
So something like this:
<ListView>
<ListView.View>
<GridView/>
</ListView.View>
</ListView>
Cory