| ??? 03/12/08 06:03 Read: times |
#152145 - sprintf() works fine. Responding to: ???'s previous message |
you need %ul ( as in UL) as the specifier. Of course sprintf() is big so your own is a good idea to.
assume value =12345 The method is do a moduls 10 on value. you get 5. 5 + '0' = ASCII '5'. then you divide value by 10. value = 1234. repeat until value = 0. the use of the div() function my speed it up. |
| Topic | Author | Date |
| converting a long to acsii char * | 01/01/70 00:00 | |
| sprintf() works fine. | 01/01/70 00:00 | |
| Maybe; maybe not | 01/01/70 00:00 | |
| I am going to try %ul as a sprintf specifier | 01/01/70 00:00 | |
| Oh yes it does! | 01/01/70 00:00 | |
| Mod10, than divide works tooo | 01/01/70 00:00 | |
| code example | 01/01/70 00:00 | |
| superfluous line of code | 01/01/70 00:00 | |
| better code example | 01/01/70 00:00 | |
| still applies to 'better code' | 01/01/70 00:00 | |
| How to post source code | 01/01/70 00:00 | |
Why 32 char buffer? | 01/01/70 00:00 |



