How to use Find method in dataview for multiple column sort?

  • Thread starter Thread starter ittemp
  • Start date Start date
I

ittemp

Hello

My dataview is set to sort with multiple column. But when I try to
use Find method, I only want to use one colume to find, so, how to pass the
object array to Find() that it will ignore other columns, only use the one I
want?


Thanks
 
Hi Stephen
Thanks for your Reply

But My problem is:

The following example is trying to fing CompanyName="The Cracker Box",
ContactName=Liu Wong"

But maybe I just want to find records with CompanyName="The Cracker Box".
And I can not just change the sort of datavies, because I need the dataview
sorted by "CompanyName, ContactName". In this case, How?


Dim custView As DataView = New DataView(custDS.Tables("Customers"), "", _
"CompanyName, ContactName", _
DataViewRowState.CurrentRows)

Dim foundRows() As DataRowView = custView.FindRows(New object() {"The
Cracker Box", "Liu Wong"})
 
Back
Top