views:

316

answers:

1

hello im using asp.net with vb and sql server 2005.

i have DataSet with 3 tables in it and i want to asign all 3 tables into one DataView

i know its possible to assign each table seperatly by doing this:

Dim dv as New DataView(ds.Tables(i)).DefaultView

but i need all the tables in the dataset and not only the i based index table

i also thought about using DataViewManager which can be assigned to the whole Dataset

but it doesn't have the RowFilter prophety

which i am using Later on my code.

so how do i solve this?

A: 

This article should help you

http://msdn.microsoft.com/en-us/library/4xz507ds%28VS.71%29.aspx

You can do something like this (snippet from the article)

myDataViewManager.DataViewSettings("Customers").Sort = "CompanyName"
myDataViewManager.DataViewSettings("Customers").RowFilter = "Where clause here"

Hope this helps

iHeartDucks