# Power Table keeping data on window close

**URL:** <https://forum.inductiveautomation.com/t/power-table-keeping-data-on-window-close/19283>\
**Category:** Ignition\
**Created:** [August 16, 2018, 1:42pm UTC](https://forum.inductiveautomation.com/t/power-table-keeping-data-on-window-close/19283 "2018-08-16T13:42:52Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jshaffer09](https://avatars.discourse-cdn.com/v4/letter/j/df788c/32.png) [@jshaffer09](https://forum.inductiveautomation.com/u/jshaffer09)\
**Post date:** [August 16, 2018, 1:42pm UTC](https://forum.inductiveautomation.com/t/power-table-keeping-data-on-window-close/19283/1 "2018-08-16T13:42:52Z")

</div>

when I close a window with a power table on it, the data reverts back to the existing data. Is there a way for it to retain the data that is newly entered?

---

<div class="post-metadata">

**Author:** ![ethomason](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ethomason/32/43338_2.png) [@ethomason](https://forum.inductiveautomation.com/u/ethomason)\
**Post date:** [August 16, 2018, 2:17pm UTC](https://forum.inductiveautomation.com/t/power-table-keeping-data-on-window-close/19283/2 "2018-08-16T14:17:09Z")

</div>

Where does the data come from initially? You can use the onCellEdited extension function of the power table to commit the data after editing.

---

<div class="post-metadata">

**Author:** ![jshaffer09](https://avatars.discourse-cdn.com/v4/letter/j/df788c/32.png) [@jshaffer09](https://forum.inductiveautomation.com/u/jshaffer09)\
**Post date:** [August 16, 2018, 8:56pm UTC](https://forum.inductiveautomation.com/t/power-table-keeping-data-on-window-close/19283/3 "2018-08-16T20:56:46Z")

</div>

the data comes from the table. I would I use it to commit the data.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [August 16, 2018, 9:07pm UTC](https://forum.inductiveautomation.com/t/power-table-keeping-data-on-window-close/19283/4 "2018-08-16T21:07:25Z")

</div>

You would have to store the data somewhere. You could set up a bi-directional binding to a dataset memory tag, though there are some caveats (multiple clients would be interacting with the same data, and may overwrite each others changes).  
What are you ultimately doing with this data? Answering that question helps make more sane recommendations about what the best option here is.

---

<div class="post-metadata">

**Author:** ![jshaffer09](https://avatars.discourse-cdn.com/v4/letter/j/df788c/32.png) [@jshaffer09](https://forum.inductiveautomation.com/u/jshaffer09)\
**Post date:** [August 16, 2018, 9:19pm UTC](https://forum.inductiveautomation.com/t/power-table-keeping-data-on-window-close/19283/5 "2018-08-16T21:19:29Z")

</div>

the data gets inserted to a database once all changes are done and a submit button is pushed
