      PROGRAM DELETE_CONFIRM
      EXTERNAL CONFIRM
      CALL LIB$DELETE_FILE('*.OBJ',,,,,CONFIRM)
      END
C
      INTEGER*4 FUNCTION CONFIRM(FNM,FAB)
      INCLUDE '($FABDEF)'
      INCLUDE '($XABDEF)'
      INCLUDE '($XABDATDEF)'
      CHARACTER*(*) FNM
      RECORD /FABDEF/FAB
      INTEGER*4 STAT
      CHARACTER*1 CONF
      CHARACTER*23 TIM
      STRUCTURE /MYXAB/
        UNION
          MAP
            RECORD /XABDEF/GENERAL
          ENDMAP
          MAP
            RECORD /XABDATDEF/SPECIFIC
          ENDMAP
        ENDUNION
      ENDSTRUCTURE
      RECORD /MYXAB/XAB
      INTEGER*4 SYS$OPEN,SYS$CLOSE,SYS$ASCTIM
      FAB.FAB$L_XAB=%LOC(XAB)
      XAB.GENERAL.XAB$B_BLN=XAB$C_DATLEN
      XAB.GENERAL.XAB$B_COD=XAB$C_DAT
      XAB.GENERAL.XAB$L_NXT=0
      STAT=SYS$OPEN(FAB,,)
      STAT=SYS$CLOSE(FAB,,)
      STAT=SYS$ASCTIM(,TIM,XAB.SPECIFIC.XAB$Q_CDT,)
      WRITE(*,*) FNM,' was created ',TIM
      WRITE(*,*) 'Delete (Y/N) ?'
      READ(*,'(A)') CONF
      IF(CONF.EQ.'Y'.OR.CONF.EQ.'y') THEN
        CONFIRM=1
      ELSE
        CONFIRM=0
      ENDIF
      RETURN
      END
