Extended ASCII

Post Reply
Tomass
Posts: 3
Joined: Wed Nov 05, 2014 12:22 pm
My devices: iPhone

Extended ASCII

Post by Tomass »

There is no extended ASCII for chr$. Although I have been able to
Draw the charicter save it to a file and retrieve it into another file, I have been unable to imbed the image into a print command successfully for my purposes, which are showing the equation that I am calculating in smart basic. At present there are four ASCII charicter so need their decimal values are as follows 227 or pi, 251 or square root, 248 or degrees, and 253 or squared. Any help I can get on this will be
Greatly appreciated

User avatar
Mr. Kibernetik
Site Admin
Posts: 4786
Joined: Mon Nov 19, 2012 10:16 pm
My devices: iPhone, iPad, MacBook
Location: Russia
Flag: Russia

Re: Extended ASCII

Post by Mr. Kibernetik »

As far as I understand you, you expect

Code: Select all

PRINT CHR$(251)
to print square root symbol?

I don't know what character table you were using previously to get square root symbol with code 251, but smart BASIC uses Unicode character table.

To print special characters like square root you may:
1) Use these characters directly in PRINT command:

Code: Select all

PRINT "√π"
2) Use Unicode character codes in CHR$() function:

Code: Select all

PRINT CHR$(8730)
prints square root character.

For example you can get Unicode character codes at http://unicode-table.com

Tomass
Posts: 3
Joined: Wed Nov 05, 2014 12:22 pm
My devices: iPhone

Re: Extended ASCII

Post by Tomass »

Thank you very much, I truly appreciate it.

Post Reply