Quantcast
Channel: Extended WPF Toolkit™ Community Edition
Viewing all articles
Browse latest Browse all 4964

Created Unassigned: Speed up DataGridControl checking /binding Suggestion ? [21569]

$
0
0
i am using extended datagridcontrol. Binding the datagrid by using datagrid.itemsource. I have checkbox and grouping in side the datagrid.While checking in group item, i have to automatically check all other items in that group. for that i used datagrid_currentCellChanged event.
but its taking too much time to check all items . Is there any alternative method for the same ?

here its my code
-----------------

Private Sub dgItem_CurrentCellChanged(sender As Object, e As EventArgs) Handles dgItem.CurrentCellChanged
Try
Me.itemClsPackingSectionNotification = New clsPackingSectionNotification
Me.itemClsPackingSectionNotification = Me.dgItem.CurrentItem
Dim strRecName As String = Me.itemClsPackingSectionNotification.Recipients.Trim
Dim bolSel As Boolean = Me.itemClsPackingSectionNotification.Sel
Me.listClsPackingSectionNotification = Me.dgItem.ItemsSource

Dim objSet As New List(Of clsPackingSectionNotification)
objSet = (listClsPackingSectionNotification.FindAll(Function(x) x.Recipients = strRecName))

For Each itm As clsPackingSectionNotification In objSet
If itm.Recipients = strRecName Then
If itm.Sel = True Then
itm.Sel = False
Me.itemClsPackingSectionNotification.Sel = False
Else
itm.Sel = True
Me.itemClsPackingSectionNotification.Sel = True
End If
End If
Next
dgItem.UpdateLayout()
dgItem.Items.Refresh()

Catch ex As Exception
Dim MyError As New ErrorLog
MyError.WriteToErrorLog(ex.Message, ex.StackTrace)
End Try
End Sub




i have one more doubt

while checking the checkbox in datagrid,its not change its status by single click.

what can i do for both my the problem?

Viewing all articles
Browse latest Browse all 4964

Trending Articles