TrimAll()

Category: Text

Syntax: trimAll ( text; trimSpaces; trimType )


Parameters:

textAny text expression or text field.

trimSpaces0 (False), 1 (True).

TRimType0 through 3 depending on the trim style.

Data type returned: Text

Description:

Returns text with all leading and trailing spaces removed, and takes into account different Unicode representations of spaces.

Set trimSpaces to 1 if you want to include the removal of full-width spaces between non-Roman and Roman characters. Set trimSpaces to 0 if you do not.

Characters are considered Roman if their Unicode values are less than U+2F00. Characters with values values greater than or equal to U+2F00 are considered non-Roman.

Characters within the Roman range belong to the following character blocks: Latin, Latin-1 Supplement, Latin Extended-A & B, IPA Extensions, Spacing Modifier Letters, Combining Diacritical Marks, Greek, Cyrillic, Armenian, Hebrew, Arabic, Devanagari, Bengali, Gurmukhi, Gujarati, Oriya, Tamil, Telugu, Kannada, Malayalam, Thai, Lao, Tibetan, Georgian, Hangul Jamo, and additional Latin and Greek extended blocks.

Symbols within the Roman range include punctuation characters, superscripts, subscripts, currency symbols, combining marks for symbols, letter-like symbols, number forms, arrows, math operators, control pictures, geometric shapes, dingbats, and so on.

Characters within the non-Roman range are those belonging to the CJK symbols/punctuations area, Hiragana, Katakana, Bopomofo, Hangul compatibility Jamo, Kanbun, CJK unified ideographs, and so on.

The trimType parameter controls how the function returns text in the following ways:

0

Removes spaces between non-Roman and Roman characters and always leaves one space between Roman words.

1

Always includes a half-width space between non-Roman and Roman characters and always leaves one space between Roman words.

2

Removes spaces between non-Roman characters (reducing multiple spaces between non-Roman and Roman words to 1 space) and leaves one space between Roman words.

3

Removes all spaces everywhere.


In all cases, spaces between non-Roman characters are removed.

Examples:

Function

Results

trimAll(Full_Name,1,0)

Returns James Aloysius Kinsella when the value of Full_Name is "James Aloysius Kinsella". It is useful for stripping extra spaces out of lengthy text fields.

trimAll( ")

Returns when the value of is .




: FileMaker Specifications

FileMaker 8 Product Line

Specifications and Storage Limits

Field Types and Import/Export Formats

: Calculation Functions

Working with Calculations Primer

Calculation Signatures

Calculation Functions

: Custom Functions

Custom Functions Primer

Useful Custom Functions

: Script Steps

Scripting Primer

Script Step Reference

: Quick Reference

FileMaker Error Codes

FileMaker Keyboard Shortcuts

FileMaker Network Ports

FileMaker Server Command Line Reference

FileMaker XML Reference

: Other Resources

Where to Go for More Information



FileMaker 8 Functions and Scripts Desk Reference
FileMaker 8 Functions and Scripts Desk Reference
ISBN: 0789735113
EAN: 2147483647
Year: 2004
Pages: 352

Flylib.com © 2008-2020.
If you may any questions please contact us: flylib@qtcs.net