Switch Case in OAF
In this post , We will discus about Switch Case in OAF. Switch case in OAF is used to used to dynamically switch display items in the OAF page. We creates Switch case in OAF page regions which decides which item will be display in that region based on the conditions matches in the switch case in oaf. Here below I will describe the Switch Case in OAF with Complete steps.
Steps to Create Switch Case in OAF
Step1:-Now Right Click on the Table ==> Click New and Click Bew Column.
Step5:- Now my New Column has been Created. Now Right Click on the New Column and Create Switcher as below.
Step6:-As Below Region3 is my Switcher region created in the Last step
Step7:- Now go to the Properties of the Switcher Region3 and Select the Column name which is created in the Step2 under the Existing VO. 'DeleteButton' is the VO Attribute.
Step8:- You will notice a <case> item being created under the Switcher Region.
Now we have two conditions in which we want to Display the Delete Icon Enabled and Disabled. so We need to create another case 2.To Create New Case Right Click on the Switcher region , new and then Click Case.
Step9:- Now Right Click on the First case and Create New Item as below.
Step10:-
For the Second Item, Set the following Properties
ID: DeleteEnabled
Item Style: image
Prompt: Delete
Image URL: deleteicon_enabled.gif
Rendered: True
Item Style: image
Prompt: Delete
Image URL: deleteicon_enabled.gif
Rendered: True
Make sure you are giving the ID of the Item exactly matching with the View Attribute value being returned by the "DeleteButton" in the Sql Query of VO
Step11:- Same Like Above step , create new Item under the Second Case.
Set the following properties to the First Case Item.
ID: DeleteDisable
Item Style: image
Prompt: Delete
Image URL: deleteicon_disabled.gif
Rendered: True
ID: DeleteDisable
Item Style: image
Prompt: Delete
Image URL: deleteicon_disabled.gif
Rendered: True
Step12:- Delete Switched region in oaf is created as below.
0 comments:
Post a Comment