Chr: Difference between revisions

From NSB App Studio
Jump to navigation Jump to search
Brendon (talk | contribs)
No edit summary
Brendon (talk | contribs)
No edit summary
Line 1: Line 1:
CHR(''number'')
Chr(''number'')


'''Description'''
== Description ==


CHR returns the equivalent character of an ANSI character code. The required expression, ''number'', is any numeric expression.
Chr returns the equivalent character of an ANSI character code. The required expression, ''number'', is any numeric expression.


'''Example'''
== Example ==


<pre>
<pre>
REM CHR Example
REM Chr Example
'CHR returns characters from numbers
'Chr returns characters from numbers
DIM Lowercase, Uppercase
DIM Lowercase, Uppercase
Lowercase = CHR(97)
Lowercase = Chr(97)
Uppercase = CHR(97 - 32)
Uppercase = Chr(97 - 32)
PRINT "Lowercase = " & Lowercase
PRINT "Lowercase = " & Lowercase
PRINT "Uppercase = " & Uppercase
PRINT "Uppercase = " & Uppercase
</pre>
</pre>


'''Output'''
== Output ==


<pre>
<pre>
Line 24: Line 24:
</pre>
</pre>


'''Related Items'''
== Related Items ==
 
[[asc|ASC]]
[[asc|ASC]]
[[Category:Language Reference]]

Revision as of 20:23, 8 August 2012

Chr(number)

Description

Chr returns the equivalent character of an ANSI character code. The required expression, number, is any numeric expression.

Example

REM Chr Example
'Chr returns characters from numbers
DIM Lowercase, Uppercase
Lowercase = Chr(97)
Uppercase = Chr(97 - 32)
PRINT "Lowercase = " & Lowercase
PRINT "Uppercase = " & Uppercase

Output

Lowercase = a
Uppercase = A

Related Items

ASC