1) Use a script and the step "Paste", combined with the "Paste without style" option.
2) Press Ctrl-Z (Cmd-Z on Mac) immediately after pasting to remove the styling.
3) Use an auto-enter calculation on the field like this:
TextFormatRemove ( Self )
and set it to overwrite the existing data.
Ctrl-Z works fine.
But isn't there a way to get back the former behaviour without additional intervention?
You are mistaken about the former behavior. FM has always worked this way - at least as far back as version 3. Possibly the pasted font was close enough to the standard font that you didn't notice.
This is a feature - there are times when users want to preserve the font and FM allows that. I have always used one of the steps that Mike recommended depending on what limitations my client wanted. If they only wanted to restrict fonts in specific fields, we might use the auto-enter calc. If they wanted to restrict fonts across the board, I usually use a custom menu that substitutes the "Paste" command with "Paste without style" which also will solve the problem.
No. I'm absolutely sure about the former behaviour.
I'm using the same invoice application since FM7 in which I paste the data from the client's POs.
The font change only occurs in FM14.
What former behavior?
I don't know when it changed, but it's worked this way since at least version 11.
Did you change OS? This could have caused the issue. This is an operating system issue, not a FM issue. Check this Knowledge Base article..
This article describes the copying FROM a field in FM TO another application, not the other way round, concerning here.
And as I'm using Windows and getting formatted text from the clipboard (not clipbook!) it is obviously wrong.
For me the behaviour changed the day I changed from FM10 to FM14, and I'm using FM since Version 2.
Well, then, I suggest it was changed in version 11.
Nope - wrong Knowledge base article but here is the right one.. The fix list for FM 7.0v3 includes this fix.
"1.1. Text editing
1.1.1. In Mac OS X, styled text copied from another application now retains its styles when pasted into a field in FileMaker Pro."
I believe this was only a fix for Mac because it was already working that way for Windows. And I have both Mac & Windows clients where this behavior has been consistent since FM 6.
And here's a forum discussion of this behavior from 2009.
It's possible that AlexHart had corruption in his FM7 file that was repaired in the FM 14 upgrade, but the behavior he is describing is expected.
Do a little research Alex, there are many more ways to find this information.
Actaully, I prefer a slight mod to that auto-enter calc:
It removes any leading and trailing spaces.
Of course there are more advanced trim commands that remove other white space.
Trim( textFormatRemove( self ))
Oh, absolutely. And carriage returns. Oh, how carriage returns can create issues ...
I just double checked.
I still have FM 10 on my machine.
I opened the same application in FM10 and FM14 (different file format of course), and pasted the same text in the same field.
In FM10 the text used the format defined for that field, in FM14 font and size changed.
So may be the behaviour you described has only been true for Mac.
I just can tell about my experience from 20 years of using FM in Windows.
The recommendation is still the same and has been since FileMaker 6 or so:
Use an auto-enter calc to remove formatting.