4 Replies Latest reply on May 7, 2010 9:33 AM by mrvodka

    Merging paragraphs in letters

    wcm

      Title

      Merging paragraphs in letters

      Post

      Another Newbie question –  using Filemaker 10.  I want to generate letters whose content (essentially 1 paragraph & 1 bulleted item) will vary according to the combination of values selected on a checklist.  At this point there are just 5 different combinations.   Short of creating 5 different letters (layouts) what is the best way approach?  -- how to insert/merge the appropriate paragraph (which sometimes will exceed 255 characters)? – How do I call up and where do I store the text?     

      Also -- Occasionally the letters will call for the user to do a little customizing, e.g., deleting a line that does not apply.  I don’t see any way to do this if the letter is basically a layout with merge fields.  Solution?  Finally, would I be better off leaving my letters as Word documents and exporting the fields?  (This solution seems to be cumbersome – I would prefer to have everything in Filemaker.)

        • 1. Re: Merging paragraphs in letters
          mrvodka

          I dont know your combination but normally you could just use a calculation which selectively combines the chosen text fields and put that on the print layout.

           

          However, because you said that sometimes a letter to particular people can be changed for that instance, then you would have to store the letter contents into a field. The combination of paragraphs etc can still be done but with a script.

           

          If you need further details then you will have to provide further details yourself about the combinations as well such as if a particular order matters.

          • 2. Re: Merging paragraphs in letters
            wcm

            Thanks for responding.  I know this is simple, but I’m not quite getting it, so I’ll be very specific and take it one question at a time.   I have a text field and value list called “Education” with 4 values:  GED, Final HS, HS, and College. 
            I have a calculated field, inserted as a merged field in my letter, called “Ed_Forms”.  How do I write the calcuation when two values are checked?  This is not it.

            Case (
            (Education = "GED") ;  "GED diploma and test scores";
            (Education = "FINAL High School"); "Final High School Transcript";
            (Education= "High School"); "High School Transcript";
            ((Education= "GED")  and  (Education = "College"))  ; "GED diploma and test scores and college transcript";
            ((Education = " High School ")  and  (Education = "College"))  ; "High school and and college transcript";


            "DO NOT SEND THIS LETTER!!!  YOU HAVE DONE SOMETHING TERRIBLY WRONG  IN THIS CALCULATION AND SHOULD STRONGLY CONSIDER GOING BACK TO YOUR DAY JOB."
            )

            1.    How do I write the calculation when multiple values are checked? 

            2.    If I have a lot of text to merge – should I create additional text fields that auto enters the text?  What if the text is over 255 characters?    How do I “call up” this text in my calculation?





            • 3. Re: Merging paragraphs in letters
              wcm

              Thank you, but nevermind.  I figured out the solution to my first question. (It works if part of my case statement is Education = "GED¶College") .  So simple.  It is sometimes painful being a novice.

              • 4. Re: Merging paragraphs in letters
                mrvodka

                But when you will have an issue if the checkboxes are checked out of order.

                 

                Look into the FilterValues ( ) function.

                 

                Hint - You can check to see if a value has been selected by testing to see if the check returns empty.