Consultor Eletrônico



Kbase 18774: FIND NEXT/PREV terminates FOR EACH REPEAT or procedure block
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   22/04/1999
FIND NEXT/PREV terminates FOR EACH REPEAT or procedure block

INTRODUCTION:
============

An error at a FIND NEXT/PREV statement will make your application exit
the block in which it is at that moment. Any other statement below in
the same block won't be executed. If that FIND NEXT/PREV is in the
main block, program will be terminated.

WHY YOU NEED TO KNOW THIS:
=========================

The normal behaviour of a FIND statement would make it display an
error message saying that no record was found. But in the case of a
FIND NEXT/PREV statement it is different so that a search error
would raise the ENDKEY action, which by default is UNDO,LEAVE, and
exit the block without any error message.

PROCEDURAL APPROACH:
===================

The best way to avoid this problem is adding NO-ERROR to the
FIND NEXT/PREV statements. Otherwise, you must make sure a fail this
search and the exit of the current block is not going to produce any
undesirable behaviour.

REFERENCES TO WRITTEN DOCUMENTATION:
===================================

V8 Language Reference, Volume 1, FIND Statement Notes


rmarti 22-Apr-99