Hello,
I am trying to read information from the system.in. That works now. But now I am stumbling upon a nxt problem. Does the system.in not support higher ascii values or so?
I want to get the ascii value from the last character from the input. So I do this:
Now this seems to work with normal characters. But if I insert for instance ascii value 170 or so into it (Alt+0170) then it seems to be correct in the console but it always prints 65533, which is incorrect. Anyone have any idea why those higher ascii values are not shown correctly?Code:strG = scanner.next(); iL = strG.codePointAt(strG.length()-1); System.out.println( iL );
(ps: Do I have to set some switch to accept ANSI or so?)
/update (until ascii 126 works, 127 gives no data, everything above 128 gives 65536)




Reply With Quote