I\'m trying to get rid of unnecessary symbols after decimal seperator of my double value. I\'m doing it this way:
DecimalFormat format = new DecimalFormat(\"
By
get rid of unnecessary symbols after decimal seperator of my double value
do you actually mean you want to round to e.g. the 5th decimal? Then just use
value = Math.round(value*1e5)/1e5;
(of course you can also Math.floor(value*1e5)/1e5 if you really want the other digits cut off)
Math.floor(value*1e5)/1e5