| **Navigation:**  [[templates.htm|Templates]] > [[tlrcontents.htm|Template Language Reference]] > Built-in Template Procedures >====== SLICE (return substring from string) {{c6h0068.jpg|C6H0068.jpg}} ====== | [[separator return attribute string delimiter position .htm|{{btn_prev_n.gif|Previous page}}]][[tlrcontents.htm|{{btn_home_n.gif|Return to chapter overview}}]][[split merge a single line string to multiple lines .htm|{{btn_next_n.gif|Next page}}]] | | || **SLICE(** //expression, start, end// ) {{blk2blue.jpg|blk2blue.jpg}} | **SLICE** | Returns a substring portion of the //expression// string. | | //expression// | A string constant, symbol, or expression containing the string from which to return a substring portion. | | //start// | An integer constant or symbol containing the starting position (inclusive) within the //expression// from which to extract the substring. | | //end// | An integer constant or symbol containing the ending position (inclusive) within the //expression// from which to extract the substring. | The **SLICE** procedure returns the substring portion of the //expression// string identified by the //start// and //end// position values. This is equivalent to the Clarion language string slicing operation. **Return Data Type:**     STRING **Example:** **#SET(%MySymbol,****SLICE****('ABCDE,2,4))       #!Return 'BCD'** **See Also:** [[built in template procedures.htm|Built-In Template Procedures]]