User (Old forums)MemberSeptember 16, 2008 at 4:23 amPost count: 23064
I am using xceed grid using master child relationship.
When i click on my load button the data will be fetched from a method and binding to the xceed using master child relation, but the problem is after binding the data to the xceed grid horitontal scroll is moving little bit towards right side, how can i restrict this? Please help me on this.
Thanks in advance…
Imported from legacy forums. Posted by pravi (had 1071 views)User (Old forums)MemberSeptember 16, 2008 at 11:21 amPost count: 23064
By the default, the grid will not scroll to the right when loading data, whether this is a master detail grid or not. How do you load you data? How is your grid set up? Are you bound to a DataSet that is filled from a DataTable? Or something else?
Imported from legacy forums. Posted by André (had 525 views)User (Old forums)MemberSeptember 18, 2008 at 4:38 amPost count: 23064
In my application I need to use xceed grid using master-child relation and there should be a checkbox in evevery datarow (master grid and child grid or detailgrid) in fist column.
And one more restriction is user should be able to check only one row (if user checks one checkbox then
other checkbox of each datarow (master and detailgrid) should be unchecked).
To implement this I wrote below the code. But on binding the items to my xceed grid horizontal scroll is
moving to the right side slightly and one more is when I check checkbox taking some time to select(check).
Please suggest me on this… Thanks in advance.
Private Sub bindDatatoXceedGrid(ByVal ds As DataSet)
xgcDirect.SingleClickEdit = True
xgcDirect.FixedColumnSplitter.Visible = False
xgcDirect.DataRowTemplate.CanBeSelected = False
xgcDirect.DataRowTemplate.FitHeightToEditors = True
xgcDirect.SynchronizeDetailGrids = True
xgcDirect.Columns(“Selected”).CellEditorManager = simpleCheckBox
xgcDirect.Title = “Master 1572”
If FrmDirect_ChkShwMasterSub1572.Checked And ds.Tables.Contains(“MasterSub”) Then
Dim data_relationPISub As New DataRelation(“PISub”, ds.Tables(“Master”).Columns(“Form ID”), ds.Tables(“MasterSub”).Columns(“Form ID”))
If Not ds.Relations.Contains(“PISub”) Then
Dim detailGridTemplateInv As New DetailGrid()
Dim detailcolumnDescription As New Column(“Selected”, GetType(Boolean))
Dim detailsimpleCheckBox As New CheckBoxEditor
detailGridTemplateInv.Columns(“Selected”).CellEditorManager = detailsimpleCheckBox
AddHandler detailGridTemplateInv.AddingDataRow, AddressOf Me.grid_AddingDataRow
detailGridTemplateInv.Collapsed = True
detailGridTemplateInv.Columns(i).ReadOnly = True
e.DataRow.Cells(“Selected”).Value = False
Dim tmpObj As Object
tmpObj = e.DataRow.Cells(“Selected”).CellEditorControl
AddHandler DirectCast(e.Control, Xceed.Editors.WinCheckBox).CheckedChanged, AddressOf selected_checked
Private Sub CellEditorManager_DeactivatingControl(ByVal sender As Object, ByVal e As CellEditorEventArgs)
RemoveHandler DirectCast(e.Control, Xceed.Editors.WinCheckBox).CheckedChanged, AddressOf selected_checked
If bSelectChanged Then
For i As Integer = 0 To xgcDirect.DataRows.Count – 1
bSelectChanged = False
xgcDirect.DataRows(i).Cells(“Selected”).Value = False
For j As Integer = 0 To xgcDirect.DataRows(i).DetailGrids.Count – 1
For k As Integer = 0 To xgcDirect.DataRows(i).DetailGrids(j).DataRows.Count – 1
xgcDirect.DataRows(i).DetailGrids(j).DataRows(k).Cells(“Selected”).Value = False
bSelectChanged = True
Imported from legacy forums. Posted by pravi (had 594 views)User (Old forums)MemberSeptember 19, 2008 at 3:02 pmPost count: 23064
This is just to let you know we reproduced the issue, and we are investigating it.
Imported from legacy forums. Posted by André (had 364 views)User (Old forums)MemberSeptember 22, 2008 at 5:50 amPost count: 23064
Imported from legacy forums. Posted by pravi (had 478 views)User (Old forums)MemberSeptember 30, 2008 at 4:58 pmPost count: 23064
The problem is with unbound columns, which seems to be not correctly calculated in the paint algorithm. It is difficult to provide a more complete answer at this point, apart than to say that this is a bug, and that we will certainly work to correct this in a future version, though we can’t provide a time frame at this moment.
In the meantime, there is a simple workaround. Simply do the following after then EndInit, or the SetDataBinding if there is no EndInit, and after the DataSet to which the grid is bound is filled with the data :
Imported from legacy forums. Posted by André (had 237 views)
- You must be logged in to reply to this topic.