# Automatically accept the update message in the client?

**URL:** <https://forum.inductiveautomation.com/t/automatically-accept-the-update-message-in-the-client/25935>\
**Category:** Ignition\
**Tags:** ignition79, ignition80\
**Created:** [June 19, 2019, 9:38am UTC](https://forum.inductiveautomation.com/t/automatically-accept-the-update-message-in-the-client/25935 "2019-06-19T09:38:24Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![mazeyrat](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mazeyrat/32/10955_2.png) [@mazeyrat](https://forum.inductiveautomation.com/u/mazeyrat)\
**Post date:** [June 19, 2019, 9:38am UTC](https://forum.inductiveautomation.com/t/automatically-accept-the-update-message-in-the-client/25935/1 "2019-06-19T09:38:24Z")

</div>

Is there a way to automatically accept the update message in the client.  
(for example in a client script based on editCount change)  
I have Ignition Client for TV with no mouse/keyboard.

---

<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:** [June 19, 2019, 10:04am UTC](https://forum.inductiveautomation.com/t/automatically-accept-the-update-message-in-the-client/25935/2 "2019-06-19T10:04:22Z")

</div>

You can change the Client Update Mode to Push as shown in the docs.  
I don’t know of any way to do it just for an individual client.

[https://docs.inductiveautomation.com/display/DOC80/Client+Update+Modes](https://docs.inductiveautomation.com/display/DOC80/Client+Update+Modes)

---

<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:** [June 19, 2019, 3:37pm UTC](https://forum.inductiveautomation.com/t/automatically-accept-the-update-message-in-the-client/25935/3 "2019-06-19T15:37:12Z")

</div>

Something along these lines (untested) should work. You’ll need to run it from some component - maybe a timer component periodically on a docked window or something like that:

```auto
from com.inductiveautomation.ignition.client.util.gui import IgnitionSwingUtilities
from com.inductiveautomation.factorypmi.application.runtime import ClientPanel

clientPanel = IgnitionSwingUtilities.getAncestorOfClass(ClientPanel, self)

clientPanel.updateBar.getLabel().doClick()

```

---

<div class="post-metadata">

**Author:** ![mazeyrat](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mazeyrat/32/10955_2.png) [@mazeyrat](https://forum.inductiveautomation.com/u/mazeyrat)\
**Post date:** [June 20, 2019, 1:00pm UTC](https://forum.inductiveautomation.com/t/automatically-accept-the-update-message-in-the-client/25935/4 "2019-06-20T13:00:11Z")

</div>

In Ignition 8.0, clientPanel can’t access updateBar

```auto
AttributeError: 'com.inductiveautomation.factorypmi.application.run' object has no attribute 'updateBar'

```

I have tried to use **clientPanel.doUpdateProject()** according to :  
[http://files.inductiveautomation.com/sdk/javadoc/ignition80/8.0.0-beta/index.html](http://files.inductiveautomation.com/sdk/javadoc/ignition80/8.0.0-beta/index.html)  
but I have the following error :

```auto
AttributeError: 'com.inductiveautomation.factorypmi.application.run' object has no attribute 'doUpdateProject'

```

Any idea ?

---

<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:** [June 20, 2019, 3:22pm UTC](https://forum.inductiveautomation.com/t/automatically-accept-the-update-message-in-the-client/25935/5 "2019-06-20T15:22:30Z")

</div>

Try importing FieldUtils and reading the (package-private) `updateBar` field:  
[https://commons.apache.org/proper/commons-lang/apidocs/org/apache/commons/lang3/reflect/FieldUtils.html#readField-java.lang.Object-java.lang.String-](https://commons.apache.org/proper/commons-lang/apidocs/org/apache/commons/lang3/reflect/FieldUtils.html#readField-java.lang.Object-java.lang.String-)
