numbers into words

numbers into words

Hi,
I have decimal field in a form.I need convert that field number into words(for example: 123654=one lakh twenty three thousand six hundred and fifty four).I try to write a function  to convert that number into words but it didn't work.I also referred in zoho forums for that,But It has a code for international numbering system(BILLION,MILLION) ,not for  INDIAN NUMBERING SYSTEM(CRORE,LAKHS).

kindly help to write solve it.

Thank you.