trim: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - " *\| *([Cc]omments|COMMENTS|Game|[Gg]ame [Nn]ame( +[0-9])?|Game [Vv]ersion( +[0-9])?|Game Version \(number surrounded by NO SPACES\)|Arguments in MP|MP[Aa]rg|Multiplayer Arguments( \("local" or "global"\))?|Effects|Execution|Effects...) |
Lou Montana (talk | contribs) m (Text replacement - "{{Command " to "{{RV|type=command ") |
||
Line 1: | Line 1: | ||
{{ | {{RV|type=command | ||
| arma3dev | | arma3dev |
Revision as of 11:43, 24 January 2021
Description
- Description:
- Description needed
- Groups:
- Strings
Syntax
- Syntax:
- Syntax needed
- Parameters:
- stringValue: String - string to be trimmed. spaces, tabs and line returns are removed from both ends of stringValue.
- Return Value:
- Return value needed
Alternative Syntax
- Syntax:
- string trim [chars, where]
- Parameters:
- string: String - string to be trimmed
- chars: String - list of characters to be trimmed
- where: Number - Can be:
- 0 - trim at the beginning (left) and the end (right)
- 1 - trim at the beginning (left)
- 2 - trim at the end (right)
- Return Value:
- String - trimmed string
Examples
- Example 1:
trim " hello, how are you? "; // returns "hello, how are you?"
- Example 2:
"hewosentence!123" trim ["3e1o2hw", 0]; // returns "sentence!"
Additional Information
- See also:
- See also needed
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note