ToUpper and ToLower (String functions): Difference between revisions

From m204wiki
Jump to navigation Jump to search
mNo edit summary
 
(24 intermediate revisions by 7 users not shown)
Line 1: Line 1:
{{Template:String:ToUpper subtitle}}
{{Template:String:ToUpper and ToLower subtitle}}


{{Template:String:ToLower subtitle}}
The <var>ToUpper</var> and <var>ToLower</var> functions return the alphabetic characters in the method object string as all-uppercase or all-lowercase characters, respectively. Non-alphabetic characters are returned as is, and the input string undergoes no other change.


The ToUpper and ToLower functions return the alphabetic characters in the method object string as all-uppercase or all-lowercase characters, respectively. Non-alphabetic characters are returned as is, and the input string undergoes no other change.                                 
==Syntax==
                                                                                 
These functions are available as of [[Sirius Mods]] version 7.3.                 
===ToUpper and ToLower syntax===                                                 
{{Template:String:ToUpper syntax}}
{{Template:String:ToUpper syntax}}
{{Template:String:ToLower syntax}}
{{Template:String:ToLower syntax}}
===Syntax Terms===                                                                
===Syntax terms===
<dl>                                                                              
<table class="syntaxTable">
<dt>%outStr                                                                       
<tr><th>%outString</th>
<dd>A string or Longstring to receive the all-uppercase or all-lowercase characters converted from the input string.                        
<td>A string to receive the all-uppercase or all-lowercase characters converted from the input string.</td></tr>
<dt>string                                                                        
<tr><th>string</th>
<dd>The input string or Longstring.                                              
<td>The input, method object <var class="term">string</var>.</td></tr>
                                                                                 
</table>
</dl>                                                                            
===Examples===                                                                   
                                                                                 
Example ToUpper and ToLower statements follow:                                   
    . . .                                                                       
    %s is longstring                                                             
    %s = 'A c E g ?4lN ,8, t v { Z'                                               
    [[Intrinsic classes#printtext|printText]] {~} = '{%s:toUpper}'                       
    printText {~} = '{%s:toLower}'                                               
    . . .                                                                       
                                                                                 
The results are:                                                                 
    %s:toUpper = A C E G ?4LN ,8, T V { Z
    %s:toLower = a c e g ?4ln ,8, t v { z


===See also===                           
==Usage notes==
[[List of intrinsic String methods]]
<ul><li>These functions are available as of <var class="product">Sirius Mods</var>  Version 7.3.</ul>


[[Category:Intrinsic String methods|ToUpper and ToLower function]]
==Examples==
[[Category:Intrinsic methods]]
Example <var>ToUpper</var> and <var>ToLower</var> statements follow:
<p class="code"> . . .
%s is longstring
%s = 'A c E g ?4lN ,8, t v { Z'
[[PrintText statement|printText]] {~} = '{%s:toUpper}'
printText {~} = '{%s:toLower}'
. . .
</p>
The results are:
<p class="code">%s:toUpper = A C E G ?4LN ,8, T V { Z
%s:toLower = a c e g ?4ln ,8, t v { z
</p>
 
==See also==
{{Template:String:ToUpper and ToLower footer}}

Latest revision as of 22:38, 5 November 2012

Translate to uppercase/lowercase (String class)


The ToUpper and ToLower functions return the alphabetic characters in the method object string as all-uppercase or all-lowercase characters, respectively. Non-alphabetic characters are returned as is, and the input string undergoes no other change.

Syntax

%outString = string:ToUpper

%outString = string:ToLower

Syntax terms

%outString A string to receive the all-uppercase or all-lowercase characters converted from the input string.
string The input, method object string.

Usage notes

  • These functions are available as of Sirius Mods Version 7.3.

Examples

Example ToUpper and ToLower statements follow:

. . . %s is longstring %s = 'A c E g ?4lN ,8, t v { Z' printText {~} = '{%s:toUpper}' printText {~} = '{%s:toLower}' . . .

The results are:

%s:toUpper = A C E G ?4LN ,8, T V { Z %s:toLower = a c e g ?4ln ,8, t v { z

See also