2019-10-22 05:42 AM
Hello, I am getting data in decimal format and to need to convert it into string.So how can i do it?
Solved! Go to Solution.
2019-10-22 07:09 AM
The math/logic here are pretty simple, sort of thing given as a homework assignment to check if you have some grasp of topic.
Tip:do it backward, generating the least significant digits first.
Library also has things like itoa() which is more lightweight than sprintf() and variants.
http://www.cplusplus.com/reference/cstdlib/itoa/
2019-10-22 07:02 AM
sprintf() would be the simplest way.
2019-10-22 07:09 AM
The math/logic here are pretty simple, sort of thing given as a homework assignment to check if you have some grasp of topic.
Tip:do it backward, generating the least significant digits first.
Library also has things like itoa() which is more lightweight than sprintf() and variants.
http://www.cplusplus.com/reference/cstdlib/itoa/
2019-10-31 10:12 PM
Thank you so much sir.I used itoa function and it shows correct decimal value in docklight that i required.Thank you once again sir.