Hi

I am trying to access the data adapter for a table in a dataset as below;

MyDataSet.MyTable.Clear()
MyDataSet.MyTableTableAdapter.Fill(MyDataSet.MyTable)

But I am getting a 'MyDataSet.MyTableTableAdapter' is not a member of
'MyDataSet'. What is the problem and how can I access the underlying data
adapter for the table MyTable?

Thanks

Regards

Re: Accessing data adapter in a dataset by Shawn

Shawn
Mon Feb 04 19:14:47 CST 2008

The Typed DataSet doesn't have the Table Adapter. You'll need to create
an instance of it to call Fill. These are usually in their own namespace
(Something like MyProject.MyDataSet.TableAdapters).

Thanks,

Shawn Wildermuth
Microsoft MVP (C#)
http://wildermuthconsulting.com
mailto:swildermuth@REMOVE_ALLCAPS_adoguy.com

> Hi
>
> I am trying to access the data adapter for a table in a dataset as
> below;
>
> MyDataSet.MyTable.Clear()
> MyDataSet.MyTableTableAdapter.Fill(MyDataSet.MyTable)
> But I am getting a 'MyDataSet.MyTableTableAdapter' is not a member of
> 'MyDataSet'. What is the problem and how can I access the underlying
> data adapter for the table MyTable?
>
> Thanks
>
> Regards
>



Re: Accessing data adapter in a dataset by Cor

Cor
Mon Feb 04 23:17:23 CST 2008

John,

Will you try it like this?

\\\
MyDataSet.MyTable.Clear()
dim da as New MyTableTableAdapter
da.Fill(MyDataSet.MyTable)
///

Cor