Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

convert decimal code to character

Status
Not open for further replies.

zhubert

Technical User
Nov 8, 2001
1
FR
Hi,

I would like to make a table with all the ASCIIcharacters (0 to 255). With \xx i get the corresponding character, but I can't get it with an expression (like $j*32 + $i)
Anyone knows how to do this ?
Can I get (and change) the UNICODE encoding ?

Thanks.

Bye
 
I know until 127:

set t ""
for {set i 32} {$i < 128} {incr i} { eval append t \\u[format %x $i] }
puts $t

who know after ?

ulis
 
for {set i 32} {$i<128} {incr i} {
puts &quot;[format &quot;%c&quot; $i]&quot;
}
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top