0

*Hi,

Greetings to u all ...
I am new to this website as well as in C++.
I got a question in c++.
I need to remove decimal point from amount (declared as CString)
Eg. Amt is 145.76
I need the final output as 014576 and same to be stored in the buffer.
ie. Amt has to be in 6 digits length.
What is the procedure to convert to reqd. output.
If the total digit is < 6, pad with 0
Hope i have made clear
Thanks

Anu
*

2
Contributors
2
Replies
3
Views
4 Years
Discussion Span
Last Post by anukavi
0

So you can do it by num(mod1) and as long as it's not 0 multiply by 10?
Good luck on that !

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.