Dim Sum As Integer
For Each dar As DataRow In DataTables("Statement").DataRows
Dim Str1 As String = dar("remarks")
If Str1 > "" AndAlso Str1 = "s/l" Then
msgbox(dar("Ticket"))
Dim drs As List(Of DataRow)
drs = DataTables("Statement").Select("[Ticket] = '" & dar("Ticket") & "' And ([Profit]= '' or [Profit] is null)")
For Each dr As DataRow In drs
dar("Profit") = dar("Profit")
Next
End If
Next