Skip to main content
Answer

Converting decimal to inches

  • May 16, 2025
  • 2 replies
  • 50 views

Forum|alt.badge.img

Hello,

 

 Does anyone know how to convert a decimal values to inches in report designer?

Example: Customer orders 12.50 feet in ACU on the sales order screen but want the value displayed on the report as 12ft 6inches. 

 

Thanks

Best answer by BenjaminCrisman

@etrojan28 I think you’ll need to make two fields, and have them populate side by side. It would be pretty easy to replace the ‘.’ with ‘ft’, but I think it will get tricky if there are values like 12.27, or 12.88, anything doesn’t evenly convert to a whole number. You’ll have to multiply the inches by 12 to get something like 10.56inches in the case of .88. The first field needs to look for the . and return left of the dot, the second should look for the dot and return what’s right of the field and then just add +’ft’ or +’inches’.

2 replies

BenjaminCrisman
Acumatica Employee
Forum|alt.badge.img+4
  • Acumatica Support Team
  • Answer
  • May 16, 2025

@etrojan28 I think you’ll need to make two fields, and have them populate side by side. It would be pretty easy to replace the ‘.’ with ‘ft’, but I think it will get tricky if there are values like 12.27, or 12.88, anything doesn’t evenly convert to a whole number. You’ll have to multiply the inches by 12 to get something like 10.56inches in the case of .88. The first field needs to look for the . and return left of the dot, the second should look for the dot and return what’s right of the field and then just add +’ft’ or +’inches’.


lauraj46
Captain II
Forum|alt.badge.img+8
  • Captain II
  • May 16, 2025

Hi ​@etrojan28 ,

For results in a single field you could use a formula like this:

=CStr(floor([SOLine.OrderQty])) + ' ft ' + CStr(CInt(([SOLine.OrderQty]-floor([SOLine.OrderQty]))*12)) + ' in'

To ​@BenjaminCrisman ‘s point, this formula will only be accurate if the decimal multiplies out evenly to a whole number.  Otherwise, you could remove the CInt and you will get all of the decimal places but it looks messier.

Hope this helps!

Laura