We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Can you help to corrrectly join to Pager dropDownChanged event ?

Hi,

In a Datagrid I need a method is recalled every time the user changes the number of elements in the page for the grid using the Pager combox.
I've seen in the documentation that this control should trigger a dropDownChanged  event.
But I'm not able to figure out how to connect to this event in the Vue environment.
Can you help me ?

3 Replies

PS Pavithra Subramaniyam Syncfusion Team June 24, 2019 04:42 AM UTC

Hi Silvio, 
 
Thanks for contacting Syncfusion support. 
 
You can handle the “dropDownChanged” event of Grid Pager component by using the below way. Please refer to the below code example, documentation and sample link for more information. 
 
[App.Vue] 
<template> 
  <div id="app"> 
    <div> 
      <ejs-grid  ref="grid"  :created="created" :allowPaging="true" :pageSettings="pageSettings" 
        :dataSource="data" > 
        <e-columns> 
          .    .    . 
        </e-columns> 
      </ejs-grid> 
    </div> 
  </div> 
</template> 
 
<script> 
.   .  . 
  methods: { 
    created: function(args) {   // you can get the pager component inside the “created” event of Grid 
      this.$refs.grid.ej2Instances.pagerModule.pagerObj.dropDownChanged = e => { 
        console.log(e); 
      }; 
    } 
  }, 
  provide: { 
    grid: [Page] 
  } 
}; 
</script> 
 
 
 
Sample               : https://codesandbox.io/s/vue-template-c0edj 
 
Please get back to us if you need any further assistance on this. 
 
Regards, 
Pavithra S. 
 



SI Silvio June 24, 2019 05:51 AM UTC

Fine!
Thank you!


PS Pavithra Subramaniyam Syncfusion Team June 24, 2019 06:33 AM UTC

Hi Silvio, 
 
Thanks for your update. 
 
Please get back to us if you need any further assistance on this. 
 
Regards, 
Pavithra S. 
 


Loader.
Live Chat Icon For mobile
Up arrow icon