User-922962635 posted
I have the following code which reads rows in a datareader
While odr.Read()
PrimaryAcctNumber = odr.GetValue(0).ToString
CustomerType = odr.GetValue(1).ToString
PaymentStatus = odr.GetValue(2).ToString
PaymentDate = odr.GetValue(3).ToString
PaymentReason = odr.GetValue(4).ToString
Source = odr.GetValue(5).ToString
PaymentType = odr.GetValue(6).ToString
Amount = odr.GetValue(7).ToString
CSR = odr.GetValue(8).ToString
PaymentID = odr.GetValue(9).ToString
AppliedDate = odr.GetValue(10).ToString
RejectionDate = odr.GetValue(11).ToString
RejectionReason = odr.GetValue(12).ToString
Counter = odr.GetValue(13).ToString
CustEirMetFlag = odr.GetValue(14).ToString
insertdataintosql(PrimaryAcctNumber, CustomerType, PaymentStatus, PaymentDate, PaymentReason, Source, PaymentType, Amount, CSR, PaymentID, AppliedDate, RejectionDate, RejectionReason, Counter, CustEirMetFlag)
End While
How would I skip the first 2 rows of the reader? Its reading an excel spreadsheet and the first to rows of the sheet I don't require