G
Guest
Hello all -
I'm at wits end with this and I'm sure I'm doing something wrong but can't
figure out why. I have this loop below.
'OldPlayersReader skips (1st to 3rd to 5th)
While pastDeadlineReader.Read And oldPlayersReader.Read
If oldPlayersReader Is Nothing Then
'If nothing set to blank.
strName = ""
Else
'Set value from OldPlayersReader to strName
strName = Convert.ToInt32(oldPlayersReader.GetValue(1))
End If
End While
So basically I have 2 readers that need to stay in sync with each other and
move along at the same time. Both will have 5 records in them always but I
need to do comparative checks in case values from OldPlayersReader need to be
used. The first time it goes through this loop, the first records are
compared but when it comes back up again, the first (pastDeadlineReader)
reader is on the 2nd record and the OldPlayersReader is on the 3rd record,
past the 2nd record.
What am I doing wrong?
Much thanks,
MN
I'm at wits end with this and I'm sure I'm doing something wrong but can't
figure out why. I have this loop below.
'OldPlayersReader skips (1st to 3rd to 5th)
While pastDeadlineReader.Read And oldPlayersReader.Read
If oldPlayersReader Is Nothing Then
'If nothing set to blank.
strName = ""
Else
'Set value from OldPlayersReader to strName
strName = Convert.ToInt32(oldPlayersReader.GetValue(1))
End If
End While
So basically I have 2 readers that need to stay in sync with each other and
move along at the same time. Both will have 5 records in them always but I
need to do comparative checks in case values from OldPlayersReader need to be
used. The first time it goes through this loop, the first records are
compared but when it comes back up again, the first (pastDeadlineReader)
reader is on the 2nd record and the OldPlayersReader is on the 3rd record,
past the 2nd record.
What am I doing wrong?
Much thanks,
MN