Navigating dataset help needed

A

Aaron

I already have a dataset filled with all of the necessary records.
I am doing this on page load:

Sub PageLoad
Dim ApplicantActivityDS As DataSet
ApplicantActivityDS = GetApplicantActivity(Session("ApplicantID")) 'This
fills the dataset
FillApplicantScreen(ApplicantActivityDS)
End Sub

Sub FillApplicantScreen(ByVal ApplicantActivityDataset As DataSet)
txtActivityDate.Text =
ApplicantActivityDataset.Tables(0).Rows(0).Item(16).ToString
There are a lot more textboxes to fill from columns.
End Sub

What I would like to do is something like:
textbox1.text bound to Dataset column 1
textbox2.text bound to Dataset column 2
etc
then set the current dataset row to 0 (or determine the current row if it is
not 0)
then filltextboxes(CurrentRow)

When I click the movenext button, filltextboxes(CurrentRow + 1)
When I click the movelast button, filltextboxes(CurrentRow - 1)

I am not sure how to take all of my textboxes and bind them each to a
specific column in the dataset, as well as determine and control the row
that I am currently at.
There is a databind method for asp.net textboxes, but no datasource or
datamember.

Thanks for your help,
Aaron
 

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

Top