>> ... not 'ñ' and not '$' any idea of why?
Did you call setlocale(LC_ALL, "") at the beginning of the program?
When you type "locale" on the command line, what does it output?

gg