4 Replies Latest reply on Nov 24, 2011 7:21 PM by DavidJondreau

    Check Box help


      I did a search and couldn't find the answer here, sohere goes.


      I want to do a search and of the relative items that show up in the search I would like to have a check box next to each item so that ONLY those items checked get ported to the REPORT, then printed with only those selected items.


      Thanks in advance.

        • 1. Re: Check Box help

          Hi — Can you explain in more detail what you're trying to do, please?

          • 2. Re: Check Box help

            Lets say I do a search and I find 12 items ( fields )  in that search, BUT I only want to port 5 or 6 of those items ( firelds )  to a report to then print.


            I'm thinking if when those 12 items show up on the find I can use either a check box or button to select items to print.


            Is there a way to select items to print or not print, rather than the entire FIND?

            • 3. Re: Check Box help



              I use a select process which might work:


              Requires 3 fields in the table for which the records are being selected. I use


              zc_MarkRecords_ctx Calculated Field Calc: Case(PatternCount(zg_mark_gtx;zc_RecordID_tx);"Y")

              zg_mark_gtx Global Text Field

              zc_RecordID_tx A unique record serial number, preferrably fixed length and text


              The checkbox on the screen is the zc_MarkRecord_ctx field. I typically implement on a list veiw layout.


              The field is defined as a button with a set field calc.


              The field that is set is the zg_mark_gtx.

              The Calc is:


              If (GetField( Get ( LayoutTableName )&"::zc_markRecord_ctx")="Y";


              Replace (GetField(Get ( LayoutTableName )&"::zg_mark_gtx")

                      ; Position ( GetField(Get ( LayoutTableName )&"::zg_mark_gtx");GetField(Get ( LayoutTableName ) & "::zc_recordID_tx") ;1;1);

                       Length(GetField(Get ( LayoutTableName ) & "::zc_recordID_tx"))+1 ; "" );

              GetField(Get ( LayoutTableName ) & "::zc_recordID_tx") & ¶ &GetField(Get ( LayoutTableName ) & "::zg_mark_gtx"))


              This calc is generic and should work on any table. To start fresh you would want to set the field zg_mark_gtx to "" before the find.


              To print the report you would find the records where zc_MarkRecord_ctx  equals Y


              Hope this helps.

              • 4. Re: Check Box help

                I would use a button that adds/removes the ID of the record to a global variable ( which is cleared on the Find).  I call this "Marking" records.


                Put a button on the body of the record. The button will run a script that includes setting a global variable and then refreshing (to get conditonal formatting to show).


                The variable step could be:


                Set Variable [ $$marked ;  Let( [

                id = table::_p ID ;

                exists = not isEmpty ( filterValues ( $$marked ; id ) ;

                sub = SubtractValues ( $$marked   ; id ) ;

                add = List ( $$marked ; id ) ;

                result = If ( exists ; sub ; add )





                SubtractValues() is a handy custom function from Jonathan Stark.


                Add conditional formatting to the button to flag the records that are marked. The conditional formatting calc would be:


                not isEmpty ( filterValues ( $$marked ; table::_p ID )


                Then your report script would find the record IDs listed in the $$marked variable.