A script-enabled browser is required for this page to function properly.

TOOL_RES.Bad_File_Handle

Description

Raised when the file handle passed to Tool_Res.Rfclose is invalid.

Syntax


Tool_Res.Bad_File_Handle  EXCEPTION;

Example


/* 
** This examples uses Tool_Res.Bad_File_Handle
*/
PRODEDURE res_test IS
  resfileh   TOOL_RES.RFHANDLE;
  resfileh1  TOOL_RES.RFHANDLE;
  res1       VARCHAR2(20);
BEGIN
  /*  Open a resource file */ 
  resfileh := TOOL_RES.RFOPEN('C:/resource/test.res');
  ...
  /* Used wrong handle to close
       the resource file. */
  TOOL_RES.RFCLOSE(resfileh1);
  ...
EXCEPTION
  WHEN TOOL_RES.BAD_FILE_HANDLE THEN
    /* print error message */
    TEXT_IO.PUT_LINE('Invalid file handle.');
    /* discard the error */
    TOOL_ERR.POP;
END;