toString: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "\[\[Category:[ _]?Scripting[ _]Commands[ _]Take[ _]On[ _]Helicopters(\|.*)?\]\]" to "{{GameCategory|tkoh|Scripting Commands}}") |
Lou Montana (talk | contribs) m (Text replacement - "_{10,} " to "") |
||
Line 1: | Line 1: | ||
{{Command|Comments= | {{Command|Comments= | ||
| arma1 |Game name= | | arma1 |Game name= | ||
Line 9: | Line 8: | ||
|gr2= Arrays |GROUP2= | |gr2= Arrays |GROUP2= | ||
| Converts the supplied [[Array]] of [[Number|Numbers]] into a [[String]]. <br> | | Converts the supplied [[Array]] of [[Number|Numbers]] into a [[String]]. <br> | ||
Line 17: | Line 15: | ||
|DESCRIPTION= | |DESCRIPTION= | ||
| '''toString''' array |SYNTAX= | | '''toString''' array |SYNTAX= | ||
Line 24: | Line 21: | ||
| [[String]] |RETURNVALUE= | | [[String]] |RETURNVALUE= | ||
|x1= <code>[[hint]] [[toString]] [65,97,338];</code> returns "AaŒ"|EXAMPLE1= | |x1= <code>[[hint]] [[toString]] [65,97,338];</code> returns "AaŒ"|EXAMPLE1= | ||
|x2= <code>["test","test"] [[joinString]] [[toString]] [12345] [[splitString]] [[toString]] [12345]; // ["test","test"]</code>|EXAMPLE4= | |x2= <code>["test","test"] [[joinString]] [[toString]] [12345] [[splitString]] [[toString]] [12345]; // ["test","test"]</code>|EXAMPLE4= | ||
| [[set]], [[resize]], [[reverse]], [[select]], [[in]], [[find]], [[toArray]], [[forEach]], [[count]], [[deleteAt]], [[deleteRange]], [[append]], [[sort]], [[param]], [[params]], [[arrayIntersect]], [[splitString]], [[joinString]], [[toLower]], [[toUpper]], [[toFixed]], [[endl]], [[format]], [[formatText]], [[toLowerANSI]], [[toUpperANSI]], [http://www.utf8-chartable.de/ Unicode Character Table] |SEEALSO= | | [[set]], [[resize]], [[reverse]], [[select]], [[in]], [[find]], [[toArray]], [[forEach]], [[count]], [[deleteAt]], [[deleteRange]], [[append]], [[sort]], [[param]], [[params]], [[arrayIntersect]], [[splitString]], [[joinString]], [[toLower]], [[toUpper]], [[toFixed]], [[endl]], [[format]], [[formatText]], [[toLowerANSI]], [[toUpperANSI]], [http://www.utf8-chartable.de/ Unicode Character Table] |SEEALSO= |
Revision as of 03:56, 17 January 2021
Description
- Description:
- Converts the supplied Array of Numbers into a String.
The numbers in the array to be converted are the decimal Unicode representations of characters. - Groups:
- StringsArrays
Syntax
Examples
- Example 1:
hint toString [65,97,338];
returns "AaŒ"- Example 2:
["test","test"] joinString toString [12345] splitString toString [12345]; // ["test","test"]
Additional Information
- See also:
- setresizereverseselectinfindtoArrayforEachcountdeleteAtdeleteRangeappendsortparamparamsarrayIntersectsplitStringjoinStringtoLowertoUppertoFixedendlformatformatTexttoLowerANSItoUpperANSIUnicode Character Table
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
Notes
Bottom Section
- Posted on February 10, 2015 - 21:05 (UTC)
- DreadedEntity
-
Tabs and new lines can be created with toString [9] and toString [10], respectively. Alternatively, a new line can also be created with toString [92,110] ("\n"). If you save these strings into a variable, they can be manipulated like any other string. For example, the following code will work just fine and return the expected output:
_tab = toString [9]; for "_i" from 0 to 3 do { _tab = _tab + (toString [9]); }; copyToClipboard format ["x%1x",tab];