Moveprevious throwing an error with Excel recordset
Posted on 2011-03-24
To start, I'm very new with recordsets, ADO, and all that. However I'm being thrown into the fire so to speak with debugging someone's work that used these things. With that being said, I may not be 100% accurate in how I'm describing things. If so, please forgive me.
I have an excel spread sheet with 4 columns. I have a VB script that is reading this information and entering it into an external application. So far, I'm able to read, update columns, movenext etc etc. However it seems that MovePrevious is not working with this recordset.
The recordset is using adOpenStatic and adLockOptimistic and from what I could find, these aren't making it a move forward only item.
Say my spreadsheet has 5 rows. I process the first 3 and now I'm on the 4th. If I do a MovePrevious here it errors our that "Either EoF or BoF is true..." Checking what happens with an IF statement, it says that I'm at the BoF...
TBH, I'm completely lost here. I think I'm missing something painfully obvious with this due to my lack of knowledge.