How to fetch count based on filter

Hi All ,

I am showing a pattern like bar chart in an interface i.e Total , Approved , Rejected etc . Now what I am doing is showing total count in the respective field but now as per requirement I want to show the count based on user filter .

For example Approved total request is 10 , now user filter the approved , and  the data displayed in the grid(1-5) has only 3 Approved . Then I have to change the 3 instead of 10. How to achieve this .

Thanks in Advance

  Discussion posts and replies are publicly visible