Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Exporting Carriage Returns

Featured Replies

Hello,

I'm trying to create a .txt file from a single global field in FM Advanced v8. I have entered a simple list into the field like this:

This is line 1

This is line 2

This is line 3

etc...

If I place my cursor in the global field and choose Export Field Contents, the resulting .txt file looks something like this:

This is line 1[]This is line 2[]This is line 3[]etc...

For clarification I entered square brackets [] in the sample above where there is an unknown rectangular character contained in the output.

What I am after is a .txt file that looks just like the contents of my global field.

Anybody know how to solve this dilemma?

I have the same problem!! Especially annoying when exporting to csv and it's not a searchable character to simply be able to search and replace with line break :)

The only way i've got around it is to use an export field which uses substitute "p" with another symbol that's searchable so I can atleast do a search and replace with line break.

Anyone else got ideas?

  • Author

What I'm experimenting with now is having FileMaker replace all "¶" with a "~" before doing the export. Then I'm planning on writing a vbscript that will open the file and replace all "~" with chr(13) + chr(10) before re-saving the file.

I think this will work but it seems like a lot of goofing around to accomplish a simple task.

There are various ways to accomplish this.

One of the more common methods is to use one of the file plug-ins (eg Troi File) to remotely replace all the [] characters (ascii char#013) in the exported file.

However that is by no means the only method. Another one involves the use of a utility table and a scripted export. It takes a moment or two to set up, but has the advantage of being entirely native and seamlessly x-plat.

I'm attaching a quick example of ths latter technique in action. :)

CR_export.zip

You can write a script to breakout the field into separate records into another table, then export this table.

Is is one field, one record, or multiple?

If it's multiple you can put an extra blank (or a description) record in between each separate set of information as a spacer.

  • Author

Ray & Bass,

I see what you are suggesting. Because FileMaker inserts hard carriage returns while exporting individual RECORDS, your suggestion is to split the single field value containing soft returns into individual records in a temporary table and then export the entire SET OF RECORDS to a .txt file.

This will work for me. Thank you for your help!

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.