ADF for beginners

Sunday, 10 November 2013

Adding Execute,Upload,Delete action to my Excel using ADF Desktop integeration

Most of our clients are familiar with Excel. So what happens when our ADF communicates with Excel. Yes our ADF can also be used with Excel using ADF Desktop Integration.
This link helped me to have a basic understanding of our interactivity with Excel.

http://docs.oracle.com/cd/E37975_01/web.111240/e16180/interactiv_app.htm#sthref87

In this blog i will be adding upload,execute and Delete as a button which helps my users to upload their data to database,Delete the data,Execute and see the result.

First we will be creating a Fusion web app having Model and View Controller. Right click the view Controller in All Features Tab ----> Client tier -----> ADF Desktop Integration. Click the Excel workbook which creates a workbook.









This workbook will be added in the View Controller and Excel folder.
Before that create a page definition file as shown below.




I have used the employee table to be shown in my Excel. If you double click the Excel which we have created it will ask for the page definition to be added.




Choose the page Definition file it will be appeared on the left side of work book in Bindings tab.
Click the EmployyesView1(tree) and press Insert Binding a table format will be formed in the Excel workbook. In select component click an ADF Table and press ok.

As soon as Insert component dialog appears go to Batch options CommitBatchActionID should be commit.


Similarly we need to change the following properties as shown  below.

Now our table should like as below.

Click the execute action in the Binding and after pressing Insert Binding a popup will be appearing asking for ADF Button and ADF Ribbon Command.

After pressing ADF Button another insert component dialog will appear in that expand Click Action set within that expand Actions if we click the Actions(3) an button will be appearing when we click that Edit Actions dialog is opened. In the Add click the down arrow select component action an extra member is added. From the action of newly added member select download and annotation will be query.

Click ok to close all the dialog. Now the Execute button has been created in my Excel.
Insert a ADF Button from the component Dialog,insert component expand Click Action Set --> Actions--> Edit Action dialog will be open. From Add choose component action in the action field select upload.



Click ok to close the window and upload button has been created.

Select the delete action from binding click insert binding. As we did for Execute action we will providing action set for Delete. In the command action form action we will be selecting DeletFlaggedRows.

Click ok to close the window.
Now Run the Excel sheet. First click the Execute button it will populate the data's in your excel columns.

Right click and insert a new row a changed column will be populated with upper arrow symbol which defines the new row is ready as shown below.

Now insert the date and press upload button the data will be uploaded. Double click the flagged column a dot symbol will be appeared if we click the Delete button the row will get delete from the database.


This can also be achieved via ADF Ribbon command Button.

No comments:

Post a Comment