# Summation of data in ignition designer

**URL:** <https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878>\
**Category:** Ignition\
**Tags:** database, vision, scripting\
**Created:** [October 6, 2022, 2:15am UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878 "2022-10-06T02:15:11Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Juan\_Galvez](https://avatars.discourse-cdn.com/v4/letter/j/9fc348/32.png) [@Juan\_Galvez](https://forum.inductiveautomation.com/u/Juan_Galvez)\
**Post date:** [October 6, 2022, 2:15am UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/1 "2022-10-06T02:15:11Z")

</div>

Hi everyone, its the first time I enter to this forum (sorry for the bad english), recently I start to work with ignition designer, and when I was working I got stuck i my project I have a display with an initial value of 189 (tag already created) its my TakTime, then with the help of a timer I start decrasing the value by 1 every second going into 0 an then into negative numbers, and finally I have a Reset button that set the value of the display TakTime to 189 again.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/9/e/9eb5ec2f2aa262f1a91faaaae00a21c12c226a18.png)

Then when the TakTime display go into negative the Summation start counting every negative number

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/d/9/d99b1911a549f64ec132af29505af9927fe29c59.png)

the problem is that I want the Summation display to keep the count of every time the TakTime display goes into negative numbers every cycle with the reset button, Right now every time I start a new cycle and the TakTime goes to negative, the summation display start from 1 again and not the cuont from the past cycle

---

<div class="post-metadata">

**Author:** ![DavidWisely](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/davidwisely/32/10482_2.png) [@DavidWisely](https://forum.inductiveautomation.com/u/DavidWisely)\
**Post date:** [October 6, 2022, 4:43am UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/2 "2022-10-06T04:43:46Z")

</div>

It would help if you showed the expression or logic that you are using for the summation.

---

<div class="post-metadata">

**Author:** ![Juan\_Galvez](https://avatars.discourse-cdn.com/v4/letter/j/9fc348/32.png) [@Juan\_Galvez](https://forum.inductiveautomation.com/u/Juan_Galvez)\
**Post date:** [October 6, 2022, 4:55pm UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/3 "2022-10-06T16:55:56Z")

</div>

Yeah thats the problem, I still dont know enough about scrip, so yeah about the logic for the summation I still dont have any idea about how to do it, right now I only have and if, to show in the display the numbers when the TakTime goes negative

![Screenshot_20221006_105426](https://us1.discourse-cdn.com/inductiveautomation/original/3X/a/5/a5aea1818fa4db0c5e1c134c55f0d2e573893e9a.jpeg)

---

<div class="post-metadata">

**Author:** ![Arnaud\_Declerck](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/arnaud_declerck/32/44872_2.png) [@Arnaud\_Declerck](https://forum.inductiveautomation.com/u/Arnaud_Declerck)\
**Post date:** [October 6, 2022, 8:59pm UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/4 "2022-10-06T20:59:50Z")

</div>

you need to have some memory of the previous value in summation and adding that to the surent value. in your binding you just invert the actual value of taktime without taking the already set value in summation.

when reset is press I would put the actual value of summation in a memory tag and just add in my expression.  
if (taktime \<0, memSummation + (taktime\*-1),memSummation)

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [October 6, 2022, 9:17pm UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/5 "2022-10-06T21:17:52Z")

</div>

@Juan_Galvez, Tip: use the \</\> code formatting button to preserve code indentation and apply syntax highlighting. It's essential for Python and makes any code much easier to read. It also means we can copy it into our answers without having to type it all out again.  
Post an image if you need to show context.

---

<div class="post-metadata">

**Author:** ![Juan\_Galvez](https://avatars.discourse-cdn.com/v4/letter/j/9fc348/32.png) [@Juan\_Galvez](https://forum.inductiveautomation.com/u/Juan_Galvez)\
**Post date:** [October 7, 2022, 2:01am UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/6 "2022-10-07T02:01:36Z")

</div>

Thanks i would investigate about the memory tag, i think this is what i need

---

<div class="post-metadata">

**Author:** ![Juan\_Galvez](https://avatars.discourse-cdn.com/v4/letter/j/9fc348/32.png) [@Juan\_Galvez](https://forum.inductiveautomation.com/u/Juan_Galvez)\
**Post date:** [October 7, 2022, 2:03am UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/7 "2022-10-07T02:03:24Z")

</div>

Thanks I never try python, i would start investigate about some courses online to start learning

---

<div class="post-metadata">

**Author:** ![pascal.fragnoud](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pascal.fragnoud/32/24728_2.png) [@pascal.fragnoud](https://forum.inductiveautomation.com/u/pascal.fragnoud)\
**Post date:** [October 7, 2022, 5:51am UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/8 "2022-10-07T05:51:59Z")

</div>

> [@Arnaud\_Declerck](#):
>
> memSummation + (taktime\*-1)

Or `memSummation - takTime`

---

<div class="post-metadata">

**Author:** ![Arnaud\_Declerck](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/arnaud_declerck/32/44872_2.png) [@Arnaud\_Declerck](https://forum.inductiveautomation.com/u/Arnaud_Declerck)\
**Post date:** [October 7, 2022, 5:55am UTC](https://forum.inductiveautomation.com/t/summation-of-data-in-ignition-designer/64878/9 "2022-10-07T05:55:14Z")

</div>

Of course it's the same 😅 we will say it was late in the evening yesterday 😛

Thanks for the feedback @pascal.fragnoud
