J
johnb41
I'm attempting to display a datagrid with an EXTRA column: a checkbox
column. I successfully added it by creating a DataGridBoolColumn:
Dim ts1 As New DataGridTableStyle
ts1.MappingName = "Archive"
Dim colDiscontinued As New DataGridBoolColumn
With colDiscontinued
.MappingName = "abc"
.HeaderText = "xyz"
.Width = 80
End With
ts1.GridColumnStyles.Add(colDiscontinued)
DataGrid1.TableStyles.Add(ts1)
This works. BUT the resulting Datagrid ONLY shows this checkbox
column. I want this column to show up in addition to all the default
columns. Do I have to write code to show all the other columns, or is
there a simple way?
Also, I don't want to MAP this checkbox column with anything. I just
need checkboxes to show up next to each column for the user to click
on. Then i'll write code to determine what rows were selected and then
do something with them. If i leave the .Mappingname property blank,
the column just disappears. Any help/advice for this?
Thanks so much for all your help!
John
column. I successfully added it by creating a DataGridBoolColumn:
Dim ts1 As New DataGridTableStyle
ts1.MappingName = "Archive"
Dim colDiscontinued As New DataGridBoolColumn
With colDiscontinued
.MappingName = "abc"
.HeaderText = "xyz"
.Width = 80
End With
ts1.GridColumnStyles.Add(colDiscontinued)
DataGrid1.TableStyles.Add(ts1)
This works. BUT the resulting Datagrid ONLY shows this checkbox
column. I want this column to show up in addition to all the default
columns. Do I have to write code to show all the other columns, or is
there a simple way?
Also, I don't want to MAP this checkbox column with anything. I just
need checkboxes to show up next to each column for the user to click
on. Then i'll write code to determine what rows were selected and then
do something with them. If i leave the .Mappingname property blank,
the column just disappears. Any help/advice for this?
Thanks so much for all your help!
John