Is there a reason why $calc($lower($asc(\1)-96)) has to be used? It works fine with just $asc(\1) You can also use $bvar().text for this.