API tostring

104,672pages on
this wiki
Add New Page
Talk0 Share
WoW Lua

Returns the string representation of any value.

s = tostring(arg);

Arguments Edit

Any - Value to convert to a string.

Returns Edit

String - string representation of the argument; possibly provided by the argument's metatable.

Examples Edit

tostring(123)  --Returns "123"
tostring({})  --Returns "table: ###"
tostring(function() end) --Returns "function: ###"
tostring(nil) --Returns "nil"
tostring(true) --Returns "true"

Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.

Also on Fandom

Random Wiki