InsertCharacter ( text ; index ; char )
Inserts a specified character in between each character of a specified string.
Average rating: 4.3 (32 votes) Log in to vote
George Norsworthy - Show more from this author
Bell Mountain Assoc. http://bellmountainassoc.com |
Function definition: (Copy & paste into FileMaker's Edit Custom Function window)
Inserts a specified character in between each character of a specified string. The variable "index" needs to be the length of the "text" string.
Comments
Gary, GC Consulting Sep 13, 2013 |
||
Am I missing something here? When I use this function (which is very cool, btw), it also inserts a trailing char… The above mentioned sample output is on my machine: F_i_l_e_m_a_k_e_r_ It doesn't matter in my database, but it would be nicer if the trailing char would not be there. Anyone any ideas? |
||
unix, Japan Sep 28, 2013 |
||
Case ( Index < 2 ; Text ; InsertCharacter ( Replace ( Text ; Index ; 0 ; chr ) ; Index - 1 ; chr ) ) |
||
Jorge Lopez Mar 4, 2020 |
||
How can I use this function in FM 16? It does not work with chr variable, but changing variable name it does work: Case ( Index > 1 ; InsertCharacter ( Text; Index - 1; cad ) & Middle ( Text; index; 1 ) & cad; Left ( Text; 1 ) & cad ) But when using InsertCharacter ( "FILEMAKER" ; 9 ; "_" ) the result is 8__9_ Some help about this issue? Thanks in advance and best regards |
||
Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.