Database Reference
In-Depth Information
NOTE
Since that big heading clearly reads “ Text Formatting Functions,” any reasonable person would as-
sume that this formatting applies only to text. Luckily, unreasonable people rule the world. You can
apply text formatting to any data type except a container.
TextColor() and RGB()
The TextColor() function takes two parameters: some text and a color. It returns the text
you send it in the right color. Like many computer programs, FileMaker thinks of colors in
RGB code, which defines all colors as combinations of red, green, and blue, as expressed by
numerical values. The second parameter to the TextColor() function is (almost) always the
RGB function (and FileMaker automatically adds it when you add TextColor() to your for-
mula).
This function returns a color based on three parameters: red, green, and blue. For example, if
you want to change the Full Name field to show the first name in bright red, and the last
name in bright blue, you use this calculation:
TextColor ( First Name ; RGB ( 255 ; 0 ; 0 ) )
& " " &
TextColor ( Last Name ; RGB ( 0 ; 0 ; 255 ) )
TIP
For a crash course in RGB code—including how to avoid using it—see the box on Color My World
(with 16 million Colors) .
TextFont()
To change the font in a calculation result, use the TextFont() function. You just pass it the
text you want to format and the name of the font to use. FileMaker returns the same text with
the font applied:
TextFont ( "Dewey Defeats Truman!" ; "Times New Roman" )
TextFont() also has a third optional parameter called fontScript . Most people can simply
ignore this option. It tells FileMaker which character set you're interested in, and to select
an appropriate font. (The character set determines which languages the font can be used for.)
FileMaker accepts the following fontScript values:
▪ Roman
Search WWH ::




Custom Search