Skip to Content

Background of the issue:

– A Web dynpro ABAP Application is holding a custom Adobe Interactive form on the view. There is a button named ‘Back’ on the same view on click to which the end user will be navigating to the previous view.

– In the case when the navigation to the previous view is done, the data displayed on the Adobe form is not cleared even though the code of setting the values of fields to null/space is written on the BACK button event.

– Due to this when the User comes back to the Adobe form (second view) from the first view page, still the Adobe form displays the old data in it.

Solution:

– Use of simple set_attribute method for clearing (set to space/null) is not sufficient.

– The ‘INVALIDATE’ method has to be used to invalidate the WD_CONTEXT holding Adobe data as described below.

1)     Web Dynpro Application is created in SE80 Tcode by creating the Web Dynpro component with two views as ‘View1’ and ‘View2’.

View1 has nothing but simple text to display and a button that takes the end user to the next view ‘View2’.

/wp-content/uploads/2012/04/step1_95696.png

View2 is holding a custom button (‘BACK’) type (UI element ‘BUTTON’) and an Adobe interactive Form.

/wp-content/uploads/2012/04/step1_1_95697.png

The interface for the Adobe interactive form is a XML Schema based ‘generated’ interface. The adobe form is of type ‘ZCI Layout’.

/wp-content/uploads/2012/04/step1_3_95698.pngThe View1 has the navigation linked created to the View2 in the Window of the component. Similarly, View2 has the navigation link created to View1 in window of the component.

/wp-content/uploads/2012/04/step1_4_95702.png


The context node in View2 ‘Adobe_data_src’ is bind with the Data source for the Adobe form.

2)     When the Button of ‘Back’ is clicked all the Data fields on the adobe form should be set to blank/space (like below).

Step_2.png

3)     Create an application for the component and test it via running it in the IE browser.

/wp-content/uploads/2012/04/step3_95704.png

Click on the ‘Next’ button of View1 (default view) launched. This will take the user to the next view (View2.

/wp-content/uploads/2012/04/step3_1_95708.png

Enter the text in the input field on Adobe form. Then click on Back button.

/wp-content/uploads/2012/04/step3_2_95709.png

Once the View1 is displayed, click on the ‘Next’ button and again navigate back to View2.

/wp-content/uploads/2012/04/step3_3_95711.png/wp-content/uploads/2012/04/step3_4_95710.pngBut this time the previously entered text is still in the Adobe form though we had written code on the ‘ONACTIONBACK’ event handler to clear the text_value field value before navigating to the View1.

This proves that just clearing the context variables is not sufficient.

4)     So now let’s change the code on the BACK button event handler (ONACTIONBACK) to the following and activate the component.

/wp-content/uploads/2012/04/step4_95712.png

5)     Now test the application and it will work. The data entered on the adobe form no longer will be stored in adobe form (Context of component) and it will be completely invalidated as soon as BACK button will be clicked.



To report this post you need to login first.

3 Comments

You must be Logged on to comment or reply to a post.

  1. Sreedhar Babu

    Hi Urvi,

    I followed your post for back button functionality.But it is not refreshing the adobe form data.

    In debugging i am able to see the data is getting cleared but it is not reflecting in adobe.

    could you please help me in this scenario.

    Regards.

    (0) 

Leave a Reply