I have the following code which goes to the next available record to process.
Dim ds As New DataSet
Dim strListType As String = Request.QueryString("ListType")
Dim strStatusFilter As String = ""
Select Case strListType
Case "newmember"
strStatusFilter = "Status_Ind in (1,4,6,8) and IsMember_Ind=1"
Case "nonmember"
strStatusFilter = "Status_Ind in (1,4,6,8) and IsMember_Ind=1"
End Select
ds = objClass.List(0, 10, "Due_Dt, Joined_Date ASC", "", strStatusFilter)
'go to the next record
If ds.Tables(0).Rows.Count > 0 Then
Server.Transfer("Request.aspx?Request_ID=" & ds.Tables(0).Rows(0).Item("Request_ID") & "&ListType=" & strListType)
Else
Server.Transfer("List.aspx?Status=NewMember")
End If
ObjClass.List is a method which is implemented to run a view and filter out data. I am ordering data on two columns due_dt and joined_dt.
My problem is that it goes to the same record everytime if I didnt update my due date. I just want to go to the next record if am not updating it. Ho can I have the behaviour I want? what changes I can make?
Thanks
The following statement returns the first row in the table:
To get the second row, you could use this statement:
To loop through all the rows, you could do something like this: