PC Review


Reply
 
 
VJ
Guest
Posts: n/a
 
      12th May 2004
When I am looping through a collection of rows in a dataset using a For Each
statment, how will know my rownumber for the row... This is assuming I don't
have a numbered column in my row..

Dim tbTable As DataTable = dsDataSet.Tables("Table1")
Dim rwRow As DataRow

For Each rwRow In tbTable.Rows

' How do I get the row number that is currently being processed here

Next

Thanks
VJ




 
Reply With Quote
 
 
 
 
Cor Ligthert
Guest
Posts: n/a
 
      12th May 2004
Hi VJ,

Use
for i as integer = 0 to dsDataset.Tables("Table1").rows.count-1
dim dr as datarow = dsDataset.Tables("Table1").rows(i)
'instead
next

I hope this answers your question?

Cor

> When I am looping through a collection of rows in a dataset using a For

Each
> statment, how will know my rownumber for the row... This is assuming I

don't
> have a numbered column in my row..
>
> Dim tbTable As DataTable = dsDataSet.Tables("Table1")
> Dim rwRow As DataRow
>
> For Each rwRow In tbTable.Rows
>
> ' How do I get the row number that is currently being processed here
>
> Next
>
> Thanks
> VJ
>
>
>
>



 
Reply With Quote
 
VJ
Guest
Posts: n/a
 
      13th May 2004
aah... got it..,

Thanks
VJ

"Cor Ligthert" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi VJ,
>
> Use
> for i as integer = 0 to dsDataset.Tables("Table1").rows.count-1
> dim dr as datarow = dsDataset.Tables("Table1").rows(i)
> 'instead
> next
>
> I hope this answers your question?
>
> Cor
>
> > When I am looping through a collection of rows in a dataset using a For

> Each
> > statment, how will know my rownumber for the row... This is assuming I

> don't
> > have a numbered column in my row..
> >
> > Dim tbTable As DataTable = dsDataSet.Tables("Table1")
> > Dim rwRow As DataRow
> >
> > For Each rwRow In tbTable.Rows
> >
> > ' How do I get the row number that is currently being processed here
> >
> > Next
> >
> > Thanks
> > VJ
> >
> >
> >
> >

>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Save 60% on Data Entry, Data Conversion, Data Processing Services byOffshore-Data-Entry dataentryoffshore@gmail.com Microsoft Excel Programming 0 4th Jun 2008 04:02 PM
Save 60% on Data Entry, Data Conversion, Data Processing Services byOffshore-Data-Entry dataentryoffshore@gmail.com Microsoft Excel Programming 0 4th Jun 2008 04:00 PM
Professional Data Conversion,Data Formats and Affordable Data EntryServices by Data Entry India Data Entry India Microsoft Access Form Coding 0 31st Mar 2008 11:50 AM
Data Entry Online, Data Format, Data Conversion and Data EntryServices through Data Entry Outsourcing admin.dataentryoutsourcing@gmail.com Microsoft Excel Misc 0 20th Mar 2008 12:45 PM
Data Entry Online, Data Format, Data Conversion and Data EntryServices through Data Entry Outsourcing admin.dataentryoutsourcing@gmail.com Microsoft Access Form Coding 0 20th Mar 2008 12:44 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:22 AM.