1 Reply Latest reply on Oct 6, 2011 11:39 AM by philmodjunk

    Check Boxs for reports



      Check Boxs for reports


       HI All,

      I think, I 've seen this and at the time it was a cool application.

      I was thinking of this:

      1. I have a main page with varied scripts, but what I need is this.

      a. A way or suggestion on getting
          One page or Tab that holds a series or selected number of reports.
          The trick, I can't seem to figure is to
          Get this list of reports with a CK Box before each report to select or deselect
          reports to either view or print out.

      Is there a simplified or logical way of getting a page with a bunch of reports and then
      then get them viewed or printed.

      ex.  [x]  Customers by address
             [x]  Customers by demographics
             [  ]   Customers by xyz

      Total  2 reports selected.

      [x] View

      [  ] Print

       [ chose view or print ] not together.

      So, how difficult would this be to acomplish.
      1st - Making the Report Layouts,  Then

              being able to select the ones to View or Print?

      Any ideas on getting something like this done?


      Tks In advance.





        • 1. Re: Check Boxs for reports

          Make these fields with global storage. I'd format the second field (view/print) as radio buttons as these would appear to be values where you would choose one or the other rather than both.

          The trick for processing the selections in the first checkbox is to understand how the selected values are stored in the underlying field in your database table. Each selected value is entered, separated from other selected values by a return character and they will be listed in the order in which the user clicked the corresponding checkboxes. You can see this directly if you put a copy of the check box field next to the original and then return the copy to edit box format instead of check boxes.

          Your script to parse out the different report options would look like this:

          IF [ ValueCount ( FilterValues ( YourTable::GlobalCheckBoxField ; "Customers by address" ) ) ]
              Perform Script ["Customers By Address Report"]
          Else If [ValueCount ( FilterValues ( YourTable::GlobalCheckboxField ; "Customers by demographics" ) ) ]
              Perform Script ["Customers by Demographics Report"]
          Else If [ ValueCount ( FilterValues ( YourTable::GlobalCheckboxField ; "Customers by xyz" ) ) ]
              Perform Script ["Customers by xyz Report"]
              Show Custom Dialog ["No report option was selected"]
          End If

          Each of these scripts would check your view/Print field to determine what to do with a given report once it has been created.

          Use Fields with global storage specified for this so different users can make these selections at the same time without interfering with one another. Also, with global storage, the values selected will be accessible from every layout in your file regardless of what relationships have or have not been defined.