Other than regex, you can also use mirc's binary variables to accomplish:
alias char {
if (!$1) { echo -a * Enter a number: e.g. /char <numbers> }
else { bset &b 1 $1- | echo -a $+(CHR,:,$chr(32),$bvar(&b,1-).text) }
}
alias ascii {
if (!$1) { echo -a * Enter a character: e.g. /ascii <characters> }
else { bset &b 1 $1- | echo -a $+(ASCII,:,$chr(32),$bvar(&b,1-).nword) }
}
P.S. I think sunslayer has those two aliases reversed, where the ascii one should be the char one, and vice versa.
-Edited added a check.