R
Robert Smith
Hello,
I have a datagrid bound to a dataset like so
Public Sub BindGrid(ByVal dgtrusses As DataGrid,
ByRef MyTable As DataTable)
dgtrusse.DataSource = MyTable
cm = CType(BindingContext(MyTable),
CurrencyManager)
End Sub
ts = New DataGridTableStyle(cm)
'new code to format the column
ts.MappingName = "trusses"
dgtrusses.TableStyles.Add(ts)
'B/C
ts.GridColumnStyles(11).Width = 50
ts.GridColumnStyles(11).HeaderText = "B/C"
ts.GridColumnStyles(11).NullText = ""
This is all fine except I wan't to format the 11th column
above to just show 3 decimal places, how do I do this do i
introduce a new gridcolumnstyle, if so how.
Regards
Robert
I have a datagrid bound to a dataset like so
Public Sub BindGrid(ByVal dgtrusses As DataGrid,
ByRef MyTable As DataTable)
dgtrusse.DataSource = MyTable
cm = CType(BindingContext(MyTable),
CurrencyManager)
End Sub
ts = New DataGridTableStyle(cm)
'new code to format the column
ts.MappingName = "trusses"
dgtrusses.TableStyles.Add(ts)
'B/C
ts.GridColumnStyles(11).Width = 50
ts.GridColumnStyles(11).HeaderText = "B/C"
ts.GridColumnStyles(11).NullText = ""
This is all fine except I wan't to format the 11th column
above to just show 3 decimal places, how do I do this do i
introduce a new gridcolumnstyle, if so how.
Regards
Robert