Some nitpicks to your original post: the format string looked wrong to me (one %s too much). The cast is dubious at best. A better cast would be to unsigned int. (One could start an endless discussion about the doubtful merit of user defined types in C here, but in this case cast to some user defined type clearly is not asked for - there is no user defined format specifier accompaning it ...). I guess the original type is some floating point type - using %.0f instead of the cast might also be a good alternative, that is portable.
I copied and pasted too fast. Actually, I posted the code as an example of the format, not trying to write perfect code, because I translated all variables to english and more readable names. The double %s is there because I use "from" and "to" in my code, but then I translated to a single variable name. As for the cast, I have a #define unsigned __int32 UINT32 in my code. I have one of those for every integer size, signed and unsigned.
But you're right, I should have been more carefull with the code I posted. Thanks for the remarks.