9 Replies Latest reply on Mar 23, 2017 5:22 AM by wimmmmm

    Data formatting within a merge a field

    Matty_1

      Title

      Data formatting within a merge a field

      Post

           I have a merge field that contains a few fields and a small block of text.  One field in particular is a date field, is there a way to format this date field to show the way I want it to (Wednesday, 11 Feburary, 2009) or do I have to create a caluclation field and tweak the format myself?

           I tried splitting it all up and using sliding but it isn't working and highlighting the particular area in the block doesn't allow me to use data formatting either.

        • 1. Re: Data formatting within a merge a field
          philmodjunk

               Click the text block that contains the date field to select it while in layout mode. You want to see selection handles--not selected text within the object. Then go to the Inspector's data tab and specify a date format.

               The key limitation here is that all date fields in this layout object will receive the same formatting. Since you only have one such field, there should be no problem with that.

          1 of 1 people found this helpful
          • 2. Re: Data formatting within a merge a field
            Matty_1

                 Thanks Phil I didn't bother trying that because I thought it would effect my other text fields in the same merge field but clearly it doesn't.

                  

                 What would happen if you wanted to format dates, and currency and time all in one merge field?  Seems starneg that you have to select one for the whole thing.

            • 3. Re: Data formatting within a merge a field
              philmodjunk

                   You can select each format, and each format will apply to all fields of that type within the text block. This is where you sometimes have to subsitute a calculation field to do the formatting--when say, you have two number fields in the same block and only want one to be formatted as currency.

              • 4. Re: Data formatting within a merge a field
                StevenWeinberg

                      

                     I had the following feedback written to FileMaker before I read this forum exchange.  But when I highlight a merge field in Layout mode with the text tool (can't do that with the Selection tool) the Inspector's data tab offers no formatting options.  The whole thing is greyed out as inactive.  So it presents no formatting possibility.
                      
                     Here's what I already submitted to Filemaker.  If anyone can show me where I'm going wrong I would greatly apprecuiate it.
                      
                     Steve
                     ===================================
                      
                      
                     From Help "Placing merge fields on a layout"
                     "To specify data formatting options (number, date, or time as appropriate for the field type), click the Selection tool, then click the merge field. Then select formatting options"
                      
                     This is gibberish.  
                      
                     "click the selection tool, then click the merge field"  OK so if you use the selection tool (arrow) to click inside the text box, it makes the text box "live".  then if you simply click within the merge field with the selection tool, it immediately becomes the text tool.  Essentially, you can't actually "click the merge field" at all.  ???  Gibberish.  
                      
                     Then, even if you did use the text tool to highlight the entire merge field including its << and>> symbols, you're told to select formatting options.  But in the Inspector, no formatting options for data are live.  And I can find no other place called "formatting options".  Under "Format" in the menu bar, there are no number formatting options. ???  More gibberish
                      
                     What am I missing here?  I have found formatting a merge field impossible since Filemaker 5.  I was hoping for more in FileMaker 12.
                      
                     Steve
                • 5. Re: Data formatting within a merge a field
                  philmodjunk

                       You should carefully read this thread again. To select data formatting for a text object that contains merge file objects, you DO NOT use the text tool and highlight a portion of the text in the text block. You click to select the entire text block--so that selection handles appear NOT highlighting.

                       And then you can select a data format for the entire text block, but it will only be applied to fields within the text block of an applicable data type.

                  • 6. Re: Data formatting within a merge a field
                    StevenWeinberg

                         Phil, Thank you for finally stating the truth!

                         OK.  I finally get it and I'm very happy that I do get it.  Formatting by text block.

                         Now, can we agree that's like trashing a file by emptying your hard drive.

                         It means that in the merge fields in the text I was trying to format there were both dollar numbers and % numbers.  I had to take my pick.  Format all the number merge fields as either $ or %.  That's the law in these here parts.

                         But at least once I realized how this formatting of merge field text works and recovered from my horror (FileMaker is owned by Apple, for God's sake) I had to break up my single block of text in the layout and replace it by 3 blocks of text with 3 different number formats.  I also had to edit the text so as to separate the merge fields far enough in separate sentences that I could do that.

                         So, yes, I finally achieved my goal of getting merge field numbers formatted the way I wanted them formatted.

                         But geeeesh.  Can't we do better than this?

                         Something like selecting a specific merge field within a text block with the text tool and then being able to format each merge field individually in the same text block?  If we have Siri, the iCloud, and, soon, the iTV and the iWatch, we've got to be able to find a way to format each merge field in a text block individually.

                         Oh - by the way.  I'm really not that dense.  It's just that I'm used to the intiuitive ease of using a Mac.  If someone simply understood what the average Apple user might have been expecting and was able, in the help section, to honestly say (as you did above) that "this may be lame, but you CANNOT format number merge fields in the same text block differently.  You have to separate out differrently formatted merge fields into different text blocks in the same layout so that you CAN format them differently - it really might have gotten through my stubborn spoiled Mac user head long ago. 

                         but thank you Phil.  You understood my quandry and addressed it in a way I could finally understand.

                         Steve

                          

                    • 7. Re: Data formatting within a merge a field
                      philmodjunk
                           

                                Phil, Thank you for finally stating the truth!

                           Sorry, but I simply repeated what I said from the beginning in this thread.

                           It's definitely frustrating at times, but: "like trashing a file by emptying your hard drive."?

                           It's not that bad. wink

                           Your other alternative is to replace the data merge field with a calculation field that returns text and that formats the number as desired. My choice, when this happens and I need to use this option (Separate blocks of text don't always work out right), is to use a calculation to format the simplest format and data formatting for the most complex. So if one number is for a percent and one for currency, I use a calcualtion field for currency.

                           If you use advanced, you can probably web search and acquire custom functions that do just about any type of data formatting you want.

                           And you can use a merge variable for the calculated format instead of adding a calculation field to your table if you use a bit of creative conditional formatting to assign a value to the merge variable as a side effect of the conditional format calculation.

                           That said, I'm just a fellow user. If you want to suggest an improvement and this is one area that could use it, I recommend that you click over to Feedback here and then copy/paste your post in the Feature Request Form.

                      • 8. Re: Data formatting within a merge a field
                        bokenrosie

                             I had to smile with the exchange here as I am just as dense as a few others.  It took a few times of selecting with the text tool before I realized that I had to select the entire text box.  Without the ability to then concatenate text boxes after this (IMHO archane way) of text formatting I am left to wonder why something like {{CurrentDateMMMMDDYYYY}} or similar might acheive the results we are all looking for.

                        • 9. Re: Data formatting within a merge a field
                          wimmmmm

                          Talk about hidden features!

                          Very nice finding, works for me! Thanks!