1 Reply Latest reply on Aug 29, 2018 1:55 PM by Agowda-Oracle

    Reset page item when report selection in IG changes

    Agowda-Oracle

      Hi All

       

      Im using APEX 5.1

      Ive a interactive Grid with Primary and a saved report.

      Also have some page items on the screen which are mostly LOVs

      I would like to clear /reset the page items when user selects the saved report.

      For eg

      there is LOV P1_Vendor

      while viewing Primary report, user have selected Value 'A"

      Now user views saved report 1 and I want the item P1_vendor to be clear.

      Is there a way to do this?

       

      Thanks

      Archana

        • 1. Re: Reset page item when report selection in IG changes
          Agowda-Oracle

          Hi All

           

          Got this working with below code

           

          (function($) {

              // do this after the page loads but before the IG is initialized to catch the initial events

              $(function() {

                  //

                  // listen for view change events to find out when grid views are created

                  $("#RPT").on("interactivegridreportchange", function(event, data) {

                     

                         apex.item("P551_ITEM").setValue("");

                     }      

                        }).on( "interactivegridreportsettingschange", function(event, data) {

                  

                  })

              });

             

                }   

          })(apex.jQuery);