Listbox never hits EOF oLbx:ReFresh()
Posted: Mon Aug 04, 2008 7:04 pm
In trouble-shooting a particular module .. I have a .dbf table that I use a standard wbrowse listbox. As I run thru the listbox in a do while .not. eof I use the oLbx:ReFresh() method to show the progress of the loop .. for some unknown reason .. the loop never hits the EOF and you have to hit the ESC key to get out of the look.
If I take out the oLbx:ReFresh() .. I do hit the EOF .. but if I leave in the oLbx:ReFresh() .. the record pointer never hit the eof()
FWH 8.07 ...
Here is an abreviated snipit of code
//-----------
oLBX:SetFocus()
SELECT 9
dbGoTop()
oLbx:Upstable()
SysReFresh()
DO WHILE .not. EOF()
SELECT 9
DELETE
SKIP
oLBX:ReFresh() // take this out and the loop hits eof
SysReFresh() //
SELECT 9 // never hits EOF
IF EOF()
msginfo( "eof exit" )
EXIT
ENDIF
ENDDO
oDLG1:End()
SAYING := "Batch Import Completed "
SAYING += ""+STR(nLOADED,4)+" Records Loaded"
MsgInfo( SAYING )
If I take out the oLbx:ReFresh() .. I do hit the EOF .. but if I leave in the oLbx:ReFresh() .. the record pointer never hit the eof()
FWH 8.07 ...
Here is an abreviated snipit of code
//-----------
oLBX:SetFocus()
SELECT 9
dbGoTop()
oLbx:Upstable()
SysReFresh()
DO WHILE .not. EOF()
SELECT 9
DELETE
SKIP
oLBX:ReFresh() // take this out and the loop hits eof
SysReFresh() //
SELECT 9 // never hits EOF
IF EOF()
msginfo( "eof exit" )
EXIT
ENDIF
ENDDO
oDLG1:End()
SAYING := "Batch Import Completed "
SAYING += ""+STR(nLOADED,4)+" Records Loaded"
MsgInfo( SAYING )