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.

Featured Replies

Hello FM users!

A question: Is there a way to insert a letter merge field into a standard text field?

I have layouts (hundreds, actually) in my db that are letters that can be printed. Instead of giving users access to Layout Mode in order to change the text of a letter, I just made a text field that contains the body of the letter. I ran into a problem the other day when I wanted to add a merge field into the body of the letter. I don't know how.

Anyone have any ideas?

Thanks very much

Ken

Kenneth,

what you can do is insert merge tags <<name>>, <<address>> etc inside the field.

Then, when it comes to printing, you can use a nested substitute if more than one merge field to insert the relevant information

Set Field [letterbody, Substitute(Substitute( letterbody, "<<Contact>>", Contact Name field), "<<Company>>", Company Name field)

HTH

  • Author

Thanks alot for the reply, Andy. My stomach is twisting in knots thinking of having to nest the Set Field function in all 100+ of my printing scripts.

Regards,

Ken

No, no. The+ nested Substitute[] is a calculation field that "processes" the field that the merge fields are in. The final layout (for printing) has the calculation field on it. Nothing to script, but some layouts to change.

The only disadvantage of this system is that the field that users enter into is not the field that gets printed, so any formatting (text or paragraph) or tabs applied to the entry field do not transfer to the printed version.

A big limitation for some, but otherwise a cracker of a system. I've used it and once its limitations are known it works very well -- users are pleased to have control.

  • Author

Thanks for straightening me out, Vaughan. I was thrown off when andy said "Set Field Substitute..."

I don't see formatting as a problem... these are your typical business style brief letters.

Everything was peachy until the powers that Be wanted to be able to modify these letters. Originally I wanted to export found sets to MS Word and automate printing. But I didn't design the db properly from the beginning to do all that.

Ken

Can someone try and explain how to 'export the found sets to MS Word". Or if complicated point me in the direction of documentation / web pages that may help.

Thanks

Tom,

Do a manual export of a small found set.

Save the file as a merge type.

This keeps the field names, for when you place them in your word document.

Now, you can then write a script that does

Export [ restore export order, perform without dialog].

#You can also specify the filename if you want it to go to the same file over and over again, otherwise leave it blank.

HTH

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.