Hi to all, I wish to know how to compare two decimal numbers.
I have an edit text where an user insert a value between 0.00 and 3.00.
I need to transform the value in 0.01 when the user insert a number under 0.00 and into 3 when the number is over 3.00. I have two problems:
1. the program don't work correctly when it compare a number with one or two decimal, and I've declared the variables with float type (i tryed also 'double').
2. i only need two decimals, how can i do that?
thanks to all
I have an edit text where an user insert a value between 0.00 and 3.00.
I need to transform the value in 0.01 when the user insert a number under 0.00 and into 3 when the number is over 3.00. I have two problems:
1. the program don't work correctly when it compare a number with one or two decimal, and I've declared the variables with float type (i tryed also 'double').
2. i only need two decimals, how can i do that?
thanks to all