Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adding a decimal point to a number 1

Status
Not open for further replies.

zidol

Technical User
Feb 9, 2016
24
US
I have two fields:

{Coverage.TOTALHOURS} which displays as "1.00"

{Coverage.TOTALMINUTES} which displays as "30" - No decimal point

Formula is:
{Coverage.TOTALHOURS} + {Coverage.TOTALMINUTES}

Because the {Coverage.TOTALMINUTES} does not have a decimal point, it returns "31.00" - I need it to return "1.30"

How do I fix this?

Thanks for your help - Lynn
 
If you need it to return 1.3 and not 1.5 (for 1 and a half hours) then
your formula would be:
{Coverage.TOTALHOURS} + ({Coverage.TOTALMINUTES} / 100)

If you need it to return 1.5 (for 1 and a half hours) then
your formula would be:
{Coverage.TOTALHOURS} + ({Coverage.TOTALMINUTES} / 60)
 
Great! That worked.

Thanks for your help.
 
zidol, you do realize that with a representation of 1.3 (1 hour, .3 x 100 minutes, cuz it's not 1.3 hours!) no one can use 1.3 to perform any meaningful math without handstands, backflips, explanations and disclaimers, yes?

Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
 
Yes - I do.

I meant to type 1.5 - but thanks!
 
There's an Edit button for that.

Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top