# OPC Item Path expression floor() and toInt()

**URL:** <https://forum.inductiveautomation.com/t/opc-item-path-expression-floor-and-toint/91611>\
**Category:** Ignition\
**Created:** [June 10, 2024, 11:37am UTC](https://forum.inductiveautomation.com/t/opc-item-path-expression-floor-and-toint/91611 "2024-06-10T11:37:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Remco\_Geervliet](https://avatars.discourse-cdn.com/v4/letter/r/13edae/32.png) [@Remco\_Geervliet](https://forum.inductiveautomation.com/u/Remco_Geervliet)\
**Post date:** [June 10, 2024, 11:37am UTC](https://forum.inductiveautomation.com/t/opc-item-path-expression-floor-and-toint/91611/1 "2024-06-10T11:37:54Z")

</div>

I'm about 99% sure what I'm trying to do is simply not possible, but I'd like to make sure.

My UDT has a parameter "alarmnumber". Together with the offset, I can use this to calculate the address;

alarmnumber/8 + . + alarmnumber%8

Alarm 1 becomes 0.1, alarm 6 is 0.6, alarm 10 is 1.1

The issue is, alarmnumber/8 returns float 0.875 instead of int 0. Because it's an OPC Item Tag-path, I can't seem to use either floor/toInt.

Is there a way to get this done?

Should edit to add I've tried using the { param | #0 } formatting but this rounds the 0.875 float up to a 1 int.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [June 10, 2024, 12:32pm UTC](https://forum.inductiveautomation.com/t/opc-item-path-expression-floor-and-toint/91611/2 "2024-06-10T12:32:04Z")

</div>

Make sure your `alarmnumber` parameter is an integer, not a string.
