i use ms access as back side of application.
and front side is visual basic.
i want to get random record from access table to visual basic form for online examination software.
please send answer as soon as
thanking for cooperation
Advertisements. Register and be a member of the community to get rid of them.
Private Sub PrintRows(dataSet As DataSet)
Dim thisTable As DataTable
For Each thisTable In dataSet.Tables
Dim row As DataRow
For Each row In thisTable.Rows
Dim column As DataColumn
For Each column In thisTable.Columns
Console.WriteLine(row(column))
Next column
Next row
Next thisTable
End Sub
'Use this "rval" as "row(rval)" and set
'upperbound = thisTable.Rows.Count
'lowerbound = 1
rval = CInt(Int((upperbound - lowerbound + 1) * Rnd() + lowerbound))
__________________
Quote:
There are more things in heaven and earth, Horatio,
Than are dreamt of in your philosophy.