4 Replies Latest reply on May 30, 2012 8:09 AM by art

    How to chart filtered records in a portal

    art

      A simple illustration to my problem is the following;

       

      I have a table with 3 fields and 5 records, viz. Bank, Amount and DeptCode. The table displays various amounts from the SAME DeptCode paid to 5 different banks.

       

      a) DeptCode = same for every record (DeptCode='001')

      b) Bank = 'bank1' or 'bank2' or 'bank3' or 'bank4' or 'bank5'

      c) Amount = various

       

      I can easily set up a pie chart to display Bank by Amount (5 Slices!). I display the table on a form layout by means of a portal along with 'other' information. It works well!! Something like a simple dashboard.

       

      The problem comes in when i add another 'set' of 5 records in my table, eg. DeptCode='002' with the same bank names and various Amounts. I managed to set up 2 'DeptCode' buttons with related scripts passing my selection to a variable to act as portal filter. So I can happily switch between buttons to see my selected records! (As I only need to display the selected filtered records at any one time). Once again this works correctly. My problem is HOW do I get the Chart to update each time I change the filter selection??? Can this be achieved with Filemaker Pro 12 Advanced? Any ideas ...?

       

      I could set up a different table accessing a different chart every time but this could be an enormous job especially if you ended up with 15 different deptcodes, each with 5 records ...

       

      Thanks