Code:
Dim dtUn As DataTable
dtUn= New DataTable
dtUn = BindICUN()
Dim i As Integer
Dim irow As DataRow
Dim mailBody As String = ""
Dim myRow As DataRow
Dim rowSet As DataRow()
rowSet = dtUn.Select("Distinct Member_id is not null")
Dim dt As DataTable
dt = New DataTable
dt.Columns.Add(New DataColumn("Trans_ID", GetType(Integer)))
Dim dr As DataRow
'dr("Trans_ID") = myRow("Trans_ID")
For Each myRow In rowSet
dr = dt.NewRow()
dr.ItemArray = myRow.ItemArray()
dt.Rows.Add(dr)
Next
return dt
Actually what i wan is bind the filtered record to datagridview, since after filter I don't how to bind using the datarow, so i copy datarow to rows in another datatable so can bind. Any better idea by giving sample code? or who can guide me on how to modify code above? Any help much appreciated. Thanks.
Comment