Get RecordCount or HasRows from SQLDataAdapter?

  • Thread starter Thread starter Jack Black
  • Start date Start date
J

Jack Black

Hi, all! What is the method for either testing for rows in a
recordset or returning the number of rows in a recordset from a
populated Adapter or from a DataSet? I know you can use HasRows with
a Reader, but I can't use a Reader in this particular instance...

Thanks!
Jack
 
Hi,

Dataset.tables(0).rows.count

Ken
-------------
Hi, all! What is the method for either testing for rows in a
recordset or returning the number of rows in a recordset from a
populated Adapter or from a DataSet? I know you can use HasRows with
a Reader, but I can't use a Reader in this particular instance...

Thanks!
Jack
 
Ken, thanks for the reply!

I came across a reference to <DataGrid>.Items.Count before you
replied, so I gave that a whirl and it worked (the dataset is
populating a DataGrid in this chunk of code). I'd imagine it's best
to eliminate that extra grid-population overhead... Yes, No?

Jack
 

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

Back
Top