Adsense Ad

Oracle Forms: Auto-Complete Checkbox


Here I would like to introduce a demo with an autocomplete combo box in Oracle Forms.
The solution creates a 'list block' on a stacked canvas, which is dynamically filtered depending on the key input in the combo box. Often one finds also the designation 'Combo Box incl. Filter' for the apt description of this component function. By activating the combo box, the 'list block' is expanded and dynamically refreshed with each key press:


application

1.) In the respective form the object group OG_CBOX is integrated from the cbox.olb by Drag & Copy:



2.) The Combo Box Item is placed on the inherited C - Canvas and should be adjusted accordingly.
3.) The position of the 'List-Block' has to be adjusted in the used canvas:



4.) The Autocomplete Combo Box is initiated in the WHEN-NEW-FORM-INSTANCE Trigger:

*****************************************
pkg_CBOX.populate_auto_cbox(
 'CBOX', 
 'select name, name
    from europecities 
    order by 1',
 'C.DUMMY');
*****************************************

The acquired item C.DUMMY should be replaced by the real NEXT-ITEM of the combo box.

The test of the solution can take place in the following stages:
- Click to Download Complete Package
- Scott / Tiger: SQL> @ cr_eurocities.sql
- execute and test the form chk_lboxproto2
- create new form, after 1.): take over the OG_CBOX
- execute and test the new form.

1 comment:

Wilson said...

Attachment does not open.