Length (String function): Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (1 revision)
m (1 revision)
Line 3: Line 3:
This [[Intrinsic classes|intrinsic]] function returns the length in bytes of the method object string.
This [[Intrinsic classes|intrinsic]] function returns the length in bytes of the method object string.


Length is available as of version 7.2 of the <var class=product>Sirius Mods</var>.
<var>Length</var> is available as of version 7.2 of the <var class=product>Sirius Mods</var>.
==Syntax==
==Syntax==
{{Template:String:Length syntax}}
{{Template:String:Length syntax}}
Line 9: Line 9:
<table class="syntaxTable">
<table class="syntaxTable">
<tr><th>%len                                                                                                </th>
<tr><th>%len                                                                                                </th>
<td>A variable to receive the numeric result of the Length method.                                      </td></tr>
<td>A variable to receive the numeric result of the <var>Length</var> method.                                      </td></tr>
<tr><th>string                                                                                              </th>
<tr><th>string                                                                                              </th>
<td>The string to which the method is applied.</td></tr>
<td>The string to which the method is applied.</td></tr>

Revision as of 15:32, 19 January 2011

The length of the string (String class)


This intrinsic function returns the length in bytes of the method object string.

Length is available as of version 7.2 of the Sirius Mods.

Syntax

%length = string:Length

Syntax terms

%len A variable to receive the numeric result of the Length method.
string The string to which the method is applied.

Examples

The following statement places the length of the string in %x into %y.

   %y = %x:length

The following statement places the length of the string "Tahquamenon" (that is, 11) into %y.

   %y = 'Tahquamenon':length

See also

List of intrinsic String methods