11.04.2013 Views

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

ASCII<br />

Syntax<br />

ASCII(expr)<br />

Description<br />

The <strong>UniBasic</strong> ASCII (American Standard Code for Information Interchange)<br />

function converts a string in EBCDIC (Extended Binary Coded Decimal Information<br />

Code) format to the corresponding ASCII values. Even though the ASCII function<br />

works with data in any format, its results are meaningful only when it is applied to<br />

EBCDIC data.<br />

For more information about ASCII character codes, see Appendix A, “ASCII<br />

Character Codes.”<br />

Note: Use the <strong>UniBasic</strong> commands CHAR and SEQ to convert between ASCII<br />

character and decimal value.<br />

Example<br />

In the following example, the program statement converts the EBCDIC data in the<br />

variable E.VAR to ASCII format and assigns the value to the variable A.VAR:<br />

A.VAR=ASCII(E.VAR)<br />

Related <strong>Commands</strong><br />

<strong>UniBasic</strong><br />

CHAR, CHARS, EBCDIC, SEQ<br />

ASCII 1-105

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!