Question : How to call info that is in a data set

I know this is a newbie question but I am stuck on this simple process.

I have a dataset populated with one row of information. What I need to do now is call each column of information and load it into a variable. Seems simple yet I am stuck. The five variables that I need to fill are below. The data set being used is ds. Any help is greatly appericiated.

Dim articlename As String
Dim articledate As String
Dim articlecopy As String
Dim authorsalutation As String
Dim authorname As String

Answer : How to call info that is in a data set

try:

Dim articlename As String = ds.tables(0).rows(0)(1).toString()
Dim articledate As String = ds.tables(0).rows(0)(2).toString()
Dim articlecopy As String = ds.tables(0).rows(0)(3).toString()
Dim authorsalutation As String = ds.tables(0).rows(0)(4).toString()
Dim authorname As String = ds.tables(0).rows(0)(5).toString()

assuming you have one table in ds and you want the first row columns to be assigned to your variables...
Random Solutions  
 
programming4us programming4us