How can i convert (in APEX) a String to an Integer, which corresponds to its ASCII.
What I have:
String Name = 'A';
What I want:
Integer Number = 65;
Thanks all!
The string.getChars() method works for this:
Integer[] vals;
String tmp = 'This is a test';
vals = tmp.getChars();
Documented in the official documentation in SF with an example of doing just this: