The following example uses ON ERROR to branch to an error procedure that uses DBERROR( ) to return what BDE error has occurred during the BROWSE and DBMESSAGE( ) to return what it means:

USE Clients
ON ERROR DO Recovery
COPY TO TEMP
USE TEMP
BROWSE
PROCEDURE Recovery
CLOSE DATABASES
CLEAR
IF ERROR()=239
  ? "The BDE error was error number: " + STR(DBERROR())
  ? "Which means: " + DBMESSAGE()
ELSE
  ? "No BDE error encountered"
ENDIF
RETURN