Click here to Skip to main content
14,300,951 members

C / C++ / MFC

 
GeneralRe: MovePrev() throwing 265926 error code (End Of RowsSet). Pin
Jochen Arndt8-Aug-18 0:29
mveJochen Arndt8-Aug-18 0:29 
GeneralRe: MovePrev() throwing 265926 error code (End Of RowsSet). Pin
Sampath5798-Aug-18 3:19
memberSampath5798-Aug-18 3:19 
GeneralRe: MovePrev() throwing 265926 error code (End Of RowsSet). Pin
Jochen Arndt8-Aug-18 3:21
mveJochen Arndt8-Aug-18 3:21 
GeneralRe: MovePrev() throwing -2147217837 error code. Pin
Sampath57912-Aug-18 1:36
memberSampath57912-Aug-18 1:36 
QuestionRe: MovePrev() throwing 265926 error code (End Of RowsSet). Pin
David Crow8-Aug-18 4:45
memberDavid Crow8-Aug-18 4:45 
AnswerRe: MovePrev() throwing 265926 error code (End Of RowsSet). Pin
Sampath5798-Aug-18 5:16
memberSampath5798-Aug-18 5:16 
QuestionRe: MovePrev() throwing 265926 error code (End Of RowsSet). Pin
David Crow9-Aug-18 4:56
memberDavid Crow9-Aug-18 4:56 
AnswerRe: MovePrev() throwing 265926 error code (End Of RowsSet). Pin
Stefan_Lang8-Aug-18 21:44
memberStefan_Lang8-Aug-18 21:44 
I believe Jochen was spot on with his very first remark. The documentation of CRowset::MoveFirst | Microsoft Docs[^] clearly states that
Quote:
Calls IRowset::RestartPosition to reposition the next-fetch location to the initial position (the position that was the next-fetch location when the rowset was created) and retrieves the initial row.

(emphasis mine)
In other words, your next Fetch would return the initial row at that time, no matter how many changes you made to the table in between the Move and the Fetch!

Looks like you should trust your error message and change your code accordingly.

P.S.: I just realized that it may still be considered ambiguous. However, you have to consider if (or why) the insertion of rows should affect the current Fetch position. The Insert command documentation does not indicate that it affects the Fetch position. If it would, shouldn't it say as much?
GOTOs are a bit like wire coat hangers: they tend to breed in the darkness, such that where there once were few, eventually there are many, and the program's architecture collapses beneath them. (Fran Poretto)

GeneralRe: MovePrev() throwing -2147217837 error code Pin
Sampath57912-Aug-18 5:29
memberSampath57912-Aug-18 5:29 
GeneralMessage Closed Pin
3-Sep-18 0:01
memberMember 139709523-Sep-18 0:01 
QuestionMFC Icon indicator (red/green) Pin
Maximilien6-Aug-18 7:20
memberMaximilien6-Aug-18 7:20 
AnswerRe: MFC Icon indicator (red/green) Pin
Victor Nijegorodov6-Aug-18 8:04
memberVictor Nijegorodov6-Aug-18 8:04 
AnswerRe: MFC Icon indicator (red/green) Pin
_Flaviu6-Aug-18 19:55
member_Flaviu6-Aug-18 19:55 
QuestionFind element at given index after a number of rotations Pin
Tarun Jha5-Aug-18 10:16
memberTarun Jha5-Aug-18 10:16 
QuestionRe: Find element at given index after a number of rotations Pin
David Crow5-Aug-18 12:39
memberDavid Crow5-Aug-18 12:39 
AnswerRe: Find element at given index after a number of rotations Pin
Tarun Jha5-Aug-18 22:21
memberTarun Jha5-Aug-18 22:21 
AnswerRe: Find element at given index after a number of rotations Pin
CPallini5-Aug-18 20:43
mveCPallini5-Aug-18 20:43 
GeneralRe: Find element at given index after a number of rotations Pin
Tarun Jha5-Aug-18 22:21
memberTarun Jha5-Aug-18 22:21 
AnswerRe: Find element at given index after a number of rotations Pin
Richard MacCutchan5-Aug-18 21:24
protectorRichard MacCutchan5-Aug-18 21:24 
GeneralRe: Find element at given index after a number of rotations Pin
Tarun Jha5-Aug-18 22:20
memberTarun Jha5-Aug-18 22:20 
GeneralRe: Find element at given index after a number of rotations Pin
Richard MacCutchan6-Aug-18 2:49
protectorRichard MacCutchan6-Aug-18 2:49 
GeneralRe: Find element at given index after a number of rotations Pin
DRHuff10-Aug-18 6:31
memberDRHuff10-Aug-18 6:31 
QuestionTell me about the c programming languages Pin
Member 139375164-Aug-18 17:29
memberMember 139375164-Aug-18 17:29 
AnswerRe: Tell me about the c programming languages Pin
Victor Nijegorodov4-Aug-18 20:44
memberVictor Nijegorodov4-Aug-18 20:44 
AnswerRe: Tell me about the c programming languages Pin
jfbode10297-Aug-18 7:08
memberjfbode10297-Aug-18 7:08 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.