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

Writing a User Exit in UNIX

The USER_EXIT directory is not available when you install Oracle Developer Suite on UNIX. Starting with Oracle9i Forms, the demo user exit is not shipped. However, the makefiles are available in <ORACLE_HOME>/forms/lib. You’ll have to copy the following files from the Forms 6i <ORACLE_HOME>/forms60/USEREXIT directory:

To create a user exit in UNIX, do the following:

  1. Precompile and compile the user exit code as follows:
    proc ue_samp.pc
    cc -c ue_samp.c
  2. Compile the file ue_xtb.c which holds the table of user exits:
    cc -c ue_xtb.c
  3. Relink the Forms executables with user exit:
    make -f ins_forms.mk frmwebmx EXITS="ue_xtb.o ue_samp.o"
    The makefile assumes that your user exit source code is in UE_SAMP.PC. If your file has a different name, you can either change the makefile (line EXITS=ue_xtb.o ue_samp.o) or pass the file names on the command line. For example:
    make -f ins_forms.mk frmwebmx EXITS="ue_xtb.o myexit.o"
  4. After creating frmwebmx, you should specify a Listener Servlet initialization parameter in the web.xml file.
  5. Create a form to test your user exit. The demo user exit adds two items, BLOCK1.ITEM1 and BLOCK1.ITEM2, and puts the result into BLOCK1.ITEM3.
  6. Create a form called ue_samp.fmb with a non-basetable block called BLOCK1, and three text items ITEM1, ITEM2 and ITEM3.
  7. Create a button with a WHEN-BUTTON-PRESSED trigger with the following code:
    user_exit('UE_SAMP');
    The test form does not need a connection to the database.
  8. Create an ON_LOGON trigger on form level with the following code:
    null;
  9. Save and generate the form.

    RESTRICTIONS: The required version of the pre-compiler to use must match the Required Support Files (RSF) version of Forms. Pro*C 9.0.1 is bundled with Oracle Developer Suite 10g. If you encounter FRM-40800, try renaming frmwebmx to frmweb.

About the User Exit Interface