TheSonics
asked on
Viewing DataGridBoolColumn
Hmm, i have added a column to my dataset.
Friend WithEvents dsHistoricViewCol As System.Data.DataColumn
Friend WithEvents dgtbHistoricViewColStyle As System.Windows.Forms.DataG ridBoolCol umn
When i do construct a row, i can access to my column:
nr.Item("View") = False
But when i try resizing i get a non instancied object:
dgHistoric.TableStyles("Hi storicTabl e").GridCo lumnStyles ("View").W idth = 100
Adding the column (named dsHistoricVewCol)...
Me.HistoricTable.Columns.A ddRange(Ne w System.Data.DataColumn() {Me.dsHistoricDateCol,Me.d sHistoricH ourCol, Me.dsHistoricRespCol, Me.dsHistoricViewCol})
Me.HistoricTable.TableName = "HistoricTable"
Adding the column TableStyle to list...
Me.HistoricTableStyle.Grid ColumnStyl es.AddRang e(New System.Windows.Forms.DataG ridColumnS tyle() {Me.dgtbHistoricDateColSty le, Me.dgtbHistoricHourColStyl e, Me.dgtbHistoricRespColStyl e, Me.dgtbHistoricViewColStyl e})
Standart column table style defenition
'dgtbHistoricViewColStyle
'
Me.dgtbHistoricViewColStyl e.Alignmen t = CType(resources.GetObject( "dgtbHisto ricViewCol Style.Alig nment"), System.Windows.Forms.Horiz ontalAlign ment)
Me.dgtbHistoricViewColStyl e.FalseVal ue = False
Me.dgtbHistoricViewColStyl e.HeaderTe xt = resources.GetString("dgtbH istoricVie wColStyle. HeaderText ")
Me.dgtbHistoricViewColStyl e.MappingN ame = resources.GetString("dgtbH istoricVie wColStyle. MappingNam e")
Me.dgtbHistoricViewColStyl e.NullText = resources.GetString("dgtbH istoricVie wColStyle. NullText")
Me.dgtbHistoricViewColStyl e.NullValu e = CType(resources.GetObject( "dgtbHisto ricViewCol Style.Null Value"), Object)
Me.dgtbHistoricViewColStyl e.TrueValu e = True
Me.dgtbHistoricViewColStyl e.Width = CType(resources.GetObject( "dgtbHisto ricViewCol Style.Widt h"), Integer)
'
So coming back to my initial question, why cant I see the datagridboolcolumn ?
Friend WithEvents dsHistoricViewCol As System.Data.DataColumn
Friend WithEvents dgtbHistoricViewColStyle As System.Windows.Forms.DataG
When i do construct a row, i can access to my column:
nr.Item("View") = False
But when i try resizing i get a non instancied object:
dgHistoric.TableStyles("Hi
Adding the column (named dsHistoricVewCol)...
Me.HistoricTable.Columns.A
Me.HistoricTable.TableName
Adding the column TableStyle to list...
Me.HistoricTableStyle.Grid
Standart column table style defenition
'dgtbHistoricViewColStyle
'
Me.dgtbHistoricViewColStyl
Me.dgtbHistoricViewColStyl
Me.dgtbHistoricViewColStyl
Me.dgtbHistoricViewColStyl
Me.dgtbHistoricViewColStyl
Me.dgtbHistoricViewColStyl
Me.dgtbHistoricViewColStyl
Me.dgtbHistoricViewColStyl
'
So coming back to my initial question, why cant I see the datagridboolcolumn ?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Well thanks man, it's now working. Dunno why but the UI Editor for the boolcolumn bugged and saved the wrong mappingName.
Thanks a lot for your help and the file you dropped.
Thanks a lot for your help and the file you dropped.
ASKER