An unhandled exception of type 'System.IndexOutOfRangeException' occurred in system.windows.forms.dll
this is my error. It seems to me that this error originated when I added sorting to my datagrid with the following code:
With DsMembers.Members
.DefaultView.RowFilter = "TDL = '" + tdl + "'"
If .DefaultView.Count = 0 Then
'do something
End if
Try
dgrOutput.DataSource = .DefaultView
Catch ex As Exception
MsgBox(ex.ToString)
End Try
End With
It seems to run through the code and then at the end throws the error at Line 3 which is the "Public Class Form1" line. I can't figure this out. Any help is greatly appreciated!!!
this is my error. It seems to me that this error originated when I added sorting to my datagrid with the following code:
With DsMembers.Members
.DefaultView.RowFilter = "TDL = '" + tdl + "'"
If .DefaultView.Count = 0 Then
'do something
End if
Try
dgrOutput.DataSource = .DefaultView
Catch ex As Exception
MsgBox(ex.ToString)
End Try
End With
It seems to run through the code and then at the end throws the error at Line 3 which is the "Public Class Form1" line. I can't figure this out. Any help is greatly appreciated!!!