Information générale
Catégorie:
Visual FoxPro Beta
>Sergey:
>
>You are absolutely right!!
>
>The issue is not that the count would be wrong because I would put something in the code to capture something about the bottom record before starting the DO loop.
>
>The issue is that the "skip -1" must be just before ENDDO. I did not understand that until now.
>
>Now when I am scanning down I do not necessarily have my skip code just before the ENDDO and it always works.
>
>Anyay, Sergey I can live with this now that I understand it. It seems a little odd that it works this way but now that I understand it, I can make it work.
>
>Thanks for clarifying this for me.
>
>Mike Smith
This is becauae BOF() and EOF() are fully different.
EOF() is a stable state, it is equal to RECNO()>RECCOUNT(), that is you are outside from the table.
BOF() is a unstable state, it is not equal to RECNO()=0 ( this would be the correct implementation ),
but it is equal to "RECNO()=TOPRECNO and you not to be able to go more up, and you are inside the table".
Fabio
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement