7 Replies Latest reply on Aug 30, 2011 3:20 PM by philmodjunk

    Auto-Enter Rich Text

    joelande

      Title

      Auto-Enter Rich Text

      Post

      Is it possible to auto-enter rich text formatting into a field with a new record?

       

      For example have some text bold and some text plain?

        • 1. Re: Auto-Enter Rich Text
          philmodjunk

          There are text formatting options that can specify such options you can use with your auto-enter function. You can look up "text formatting functions" in FileMaker help to get a list of them and see the syntax that you'd need to use. (Often, in FileMaker, we do the opposite by using the TextFormatRemove option to ensure that user entered text is NOT formatted--usually makes for more consistent control of text formats in reports and such.)

          • 2. Re: Auto-Enter Rich Text
            joelande

            But that can't be used in the Auto-Enter field can it?

             

            Here is what I am trying to do:

            When a new record is created, I want the field "monday" to look like this:

             

            Learning Activities:

            1. 

            2.

            Materials:

            1.

            2.

            • 3. Re: Auto-Enter Rich Text
              philmodjunk

              They most certainly can, but what you list here does not look like a good set up for a database. The number items in two different categories should be put in different portals of related records. This sould be a much simpler approach and more flexible approach.

              To demonstrate how the text format functions could produce what you want:

              TextStyleAdd ( "Learning Activities:" ; Bold ) & ¶ & "1." & ¶ & "2." & TextStyleAdd ( "Materials" ; Bold ) & ¶ & "1." & ¶ "2."

              • 4. Re: Auto-Enter Rich Text
                raybaudi

                 

                @Joel
                before you ask for help, there is a little omission in the Phil's calculation:

                TextStyleAdd ( "Learning Activities:" ; Bold ) & ¶ & "1." & ¶ & "2." & ¶ & TextStyleAdd ( "Materials:" ; Bold ) & ¶ & "1." & ¶ & "2."

                that could be written also:

                TextStyleAdd ( "Learning Activities:" ; Bold ) & "¶1.¶2.¶" & TextStyleAdd ( "Materials:" ; Bold ) & "¶1.¶2."

                • 5. Re: Auto-Enter Rich Text
                  philmodjunk

                  It could be written that way, but the results should be the same. Single paragraph operators do not need to be quoted.

                  • 6. Re: Auto-Enter Rich Text
                    raybaudi

                     @Phil

                    the little omission were instead two:

                    - ¶ & - before: TextStyleAdd ( "Materials:" ; Bold )
                    and
                    - & - before: the last "2."

                    BTW: why I can't format the text anymore ? ( just to show better which were the omissions )

                    • 7. Re: Auto-Enter Rich Text
                      philmodjunk

                      OK, see it now.