Filtering DataSet

M

Mike

Hi,

I have two question regarding retrieving results from a DataSet. First,
what is the best way to retrieve results from a dataset with a filter?
Right now I am using the DataView class. I also have a question regarding
the DataView class. Using the code below how do I cast the data returned by
the code below into a bool.

DataView modelDataView = new
DataView(base.componentDataSet.Tables["tblModels"]);
modelDataView.Sort = "strCode";
int index = modelDataView.Find(modelCode);
v = modelDataView[index]["blnV"];
f = modelDataView[index]["blnF"];

Thanks
 
K

Kevin Yu [MSFT]

Hi Mike,

I've posted a reply on the other thread whose title is "Filtering DataSet
Question".

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

--------------------
| From: "Mike" <[email protected]>
| Subject: Filtering DataSet
| Date: Mon, 20 Oct 2003 10:26:42 -0600
| Lines: 18
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <[email protected]>
| Newsgroups: microsoft.public.dotnet.framework.adonet
| NNTP-Posting-Host: 64.207.45.37
| Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP10.phx.gbl
| Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.adonet:64063
| X-Tomcat-NG: microsoft.public.dotnet.framework.adonet
|
| Hi,
|
| I have two question regarding retrieving results from a DataSet. First,
| what is the best way to retrieve results from a dataset with a filter?
| Right now I am using the DataView class. I also have a question regarding
| the DataView class. Using the code below how do I cast the data returned
by
| the code below into a bool.
|
| DataView modelDataView = new
| DataView(base.componentDataSet.Tables["tblModels"]);
| modelDataView.Sort = "strCode";
| int index = modelDataView.Find(modelCode);
| v = modelDataView[index]["blnV"];
| f = modelDataView[index]["blnF"];
|
| Thanks
|
|
|
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top