# Convert character to decimal

**URL:** <https://forum.kirupa.com/t/convert-character-to-decimal/221996>\
**Category:** flash\
**Created:** [April 10, 2007, 12:55am UTC](https://forum.kirupa.com/t/convert-character-to-decimal/221996 "2007-04-10T00:55:54Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![taerij](https://avatars.discourse-cdn.com/v4/letter/t/57b2e6/32.png) [@taerij](https://forum.kirupa.com/u/taerij)\
**Post date:** [April 10, 2007, 12:55am UTC](https://forum.kirupa.com/t/convert-character-to-decimal/221996/1 "2007-04-10T00:55:54Z")

</div>

I can’t seem to find a function to convert a character to a decimal.

Example:  
Convert string ‘A’ into its decimal form ‘65’.

Background:  
I’m trying to take an input character value (anything from a to ZZ), substring its characters, and into uppercase (eg. G, Z), covert each character to decimal (eg. 71, 90) and then reduce those numbers, such that A=0, B=1, Z = 25 and finally add them. GZ = 6+25 = 31.

It’s for an X,Y co-ord system that uses A-ZZ for X, and numbers for Y.
