Thanks a lot, xXxGuitar511, it was what I had been looking for and it works!
There is only one correction:
str_for_num (tStr, num);
in place of
str_for_number(tStr, num);