Putting FileMaker Portal Contents Into Single Piece Of Text

From Dwayne Wright PMP
Certified FileMaker Developer

WEB: www.dwaynewright.com
EMAIL: info@dwaynewright.com
TWITTER: dwaynewright
YOUTUBE: FileMakerThoughts


Please Note: If you are viewing this page in a news feeder, the images may get munged up a bit or other formatting of the posting may fail. For the best experience, please visit the journal directly by clicking (here).

There are times you may want to take the information that is in a portal and have it all in one big text string. You may want to have it readable ( say that it might be going out in an email ) or you don’t care if it’s readable ( say the information is being passed to another database or application).

The list function will provide you a return-delimited data list from a related data field or a repeating field. For the most part, this function is used for gathering related data in one large block and then using it for correspondence. For example, a list of related invoices in which you want to include in a batch email to each client in a found set. It is also possible that you would use the list function to pull a collection of related data as a list and then parse it out by using some of the value related text functions.

Here you can see a snapshot of the List function in use in my example file that shows off many of the aggregate, text, number, date and time functions.

Here is one way to do it using scripting for versions of FileMaker before 8.5 ...

PARENT FILE SCRIPT
Go To Related Records ( show only related records )
Perform Script ( External - in the child file )
Refresh Window ( Bring To Front )

CHILD FILE SCRIPT
Go to Record ( first )
SET ( a global text field ) ( equal to any header information you want in the string)
Loop
Set ( global text field) ( itself & the information you want in the record)
Go To Field ( next and exit after the last record)
End Loop
Go To Layout ( that has the global text field in it )
Copy ( the contents of the field)

This is allow you to have the contents of the related fields in the computers memory (commonly called the clipboard). From here you can do a number of things with it.

=
More info about the author and FileMaker in general, contact me at info@dwaynewright.com.

© 2008 - Dwayne Wright - dwaynewright.com

The material on this document is offered AS IS. There is NO REPRESENTATION OR WARRANTY, expressed or implied, nor does any other contributor to this document. WARRANTIES OF MERCHANT ABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE EXPRESSLY DISCLAIMED. Consequential and incidental damages are expressly excluded. FileMaker Pro is the registered trademark of FileMaker Inc.