-
Copyrights 2010 - Online Training Oracle Applications. All Rights Reserved.
|
It is a collection of data. Record Groups can be created in three types. Advantage LOV ( List of values ) Example In Object Navigator, select Record Groups Select LOV , Click on create button In the Object Navigator, we can see that LOV is created. As we have created LOV using wizard, LOV is assigned to DEPTNO item. In the property palette of DEPTNO item , Under List of Values Save the form. Keep the cursor on item DEPTNO, we can see that List of values ( hint message ) is displayed. Keep the cursor on Item Deptno and press Ctrl+L to display LOV. Select value from LOV, deptno is returned. Displaying LOV through code declare Save the form. Now, the moment you keep the cursor in DEPTNO item, LOV is displayed. Enter the following values in the form. Empno - 11 We get a message " Transaction complete: 1 records applied and saved."
Note: 50 is not value present in the LOV. We can restrict the end user to enter a value present in the LOV. In the property palette of the item DEPTNO Save the form.
Enter the following values in the form. Empno - 2222 We get a message "Invalid value for the field DEPTNO" Records Groups based on static values Open an existing form EMP_RG.fmb Column Values Click on OK Button. Name the Record Group as RG2 Creating LOV Manually In the property palette of LOV2, provide the following details Now, we need to attach LOV to the text item. Save the form. Keep the cursor on JOB and press Ctrl+L, we can see the LOV is displayed. Creating Record Group at runtime using code Built-in used to create Record Groups at run time.
Built-in for LOV
Example Create WHEN-BUTTON-PRESSED trigger and provide the following code and compile. declare errcode := populate_group ( rg_id); Now, In the above code , look at first parameter of set_lov_property ie rlov. So, now we need to create LOV with the name RLOV with null values at the design time.
In the Object Navigator, Create new LOV using LOV wizard Name the LOV as RLOV. Save the form. Click on the button, the code in the trigger WHEN-BUTTON-PRESSED is executed, at runtime Record Group is created and the LOV is displayed.
|