<snip> Where I'm having trouble majorly is converting data types. </snip> // if the ascii value of the first char is between 0-9 if(48 <= daString.charAt(0) <= 57) { long myNumber = Long.parseLong(daString); //put rounding code here }