Truncate a Double to 1 decimal place

P

Powderfinger

I need to truncate, not round, a Double number to 1 decimal place.
e.g.

Funct(4.67) = 4.6
Funct(4.61) = 4.6
Funct(1222.118566) = 1222.1
Funct(1222.198566) = 1222.1

How would I do this?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top