Hi,

Does someone could tell me an easy way to select the last row added in a
DataTable inside a DataSet ?

Something like :
DataSet.Table(myTable).SelectLastRowAdded ()

Thank you.

Re: DataSet / DataTable / Row selection by Cor

Cor
Wed Feb 04 15:52:40 CST 2004

Hi Sebastian,

Normaly

dataset.tables("myTable").rows(dataset.tables("myTable").rows.count-1)

I hope this was what you did mean?

Cor
>
> Does someone could tell me an easy way to select the last row added in a
> DataTable inside a DataSet ?
>
> Something like :
> DataSet.Table(myTable).SelectLastRowAdded ()
>



Re: DataSet / DataTable / Row selection by Sébastien

Sébastien
Thu Feb 05 10:23:58 CST 2004

I want to do somthing like :

BindingContext(DataSet, TableName).Position = LastRowAdded


"Cor" <non@non.com> a écrit dans le message de
news:%232ZxGm26DHA.2568@TK2MSFTNGP10.phx.gbl...
> Hi Sebastian,
>
> Normaly
>
> dataset.tables("myTable").rows(dataset.tables("myTable").rows.count-1)
>
> I hope this was what you did mean?
>
> Cor
> >
> > Does someone could tell me an easy way to select the last row added in a
> > DataTable inside a DataSet ?
> >
> > Something like :
> > DataSet.Table(myTable).SelectLastRowAdded ()
> >
>
>



Re: DataSet / DataTable / Row selection by Cor

Cor
Thu Feb 05 12:23:07 CST 2004

Hi Sebastian,

Than it is in my opinion
\\
CType(BindingContext(ds.Tables(0)),
CurrencyManager).position=ds.Tables(0).rows.count-1
//
I hope that was the solution?

Cor



Re: DataSet / DataTable / Row selection by Sébastien

Sébastien
Thu Feb 05 12:33:16 CST 2004

I'll try it, but I don't think it will be the real solution since I use a
DataViewManager to sort my list (so the new row I add could be somewhere
else that on the last line).

But I'll try to set the bindingcontaxt of my DataSet instead
DataSet.DefaultViewManager and see if it works.

Thank you for your help.

"Cor" <non@non.com> a écrit dans le message de
news:uPfwrVB7DHA.360@TK2MSFTNGP12.phx.gbl...
> Hi Sebastian,
>
> Than it is in my opinion
> \\
> CType(BindingContext(ds.Tables(0)),
> CurrencyManager).position=ds.Tables(0).rows.count-1
> //
> I hope that was the solution?
>
> Cor
>
>