How can I convert a CString, which has extracted the writing on a button (always a number in my app), into an ineteger that I can pass to a function taking integer values?

thanks

steve