Outdent ( )

Function stats

Average user rating
5.0000
148
411
9999
Support
FileMaker 7.0 +
Date posted
29 December 2016
Version
1
Recursive function
No

Author Info
 Steve Allen

15 functions

Average Rating 5.0

author_avatar



 

Function overview

Prototype

Outdent  ( lst;   delimiter;   qty;   tabchar )


Parameters

lst  The List from which you wish to remove indents.


delimiter  The character(s) that separates the values of the list.


qty  How many levels of indentation you want to remove.


tabchar  The character(s) that are used to accomplish the indents. (Will be removed.)


Description

Allows you to remove indentation levels from a given list.

Examples

Sample input

Outdent ( "xxxx-Hello¶xxxx-World" ; "¶" ; 1 ; "xxxx-" )


Sample output

Hello
World

 

Function code

Let ([
    tabs    = Substitute ( Right ( "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" ; qty ) ; "x" ; tabChar )
;    output    = Replace ( Substitute ( delimiter & lst ; delimiter & tabs ; delimiter ) ; 1 ; 1 ; "" )
];
output
)

// ===================================
/*

    This function is published on FileMaker Custom Functions
    to check for updates and provide feedback and bug reports
    please visit http://www.fmfunctions.com/fid/411

    Prototype: Outdent( lst; delimiter; qty; tabchar )
    Function Author: Steve Allen (http://www.fmfunctions.com/mid/148)
    Last updated: 29 December 2016
    Version: 1

*/
// ===================================

 

 

 

 

 

 

 

Top Tags

Text Parsing  (33)
List  (32)
Date  (28)
XML  (26)
Format  (23)
Sql  (22)
Dev  (20)
Debug  (17)
Layout  (15)
Interface  (15)
Text  (14)
Variables  (12)
Filter  (11)
Layout Objects  (11)
Design  (10)
Array  (8)