# Return something from an invokeAsync/invokeLater pair

**URL:** <https://forum.inductiveautomation.com/t/return-something-from-an-invokeasync-invokelater-pair/16970>\
**Category:** Ignition\
**Created:** [February 13, 2018, 7:34pm UTC](https://forum.inductiveautomation.com/t/return-something-from-an-invokeasync-invokelater-pair/16970 "2018-02-13T19:34:54Z")\
**Posts on this page:** 1\
**Showing post:** 2

<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:** [February 13, 2018, 9:31pm UTC](https://forum.inductiveautomation.com/t/return-something-from-an-invokeasync-invokelater-pair/16970/2 "2018-02-13T21:31:52Z")

</div>

See [this thread](http://forum.inductiveautomation.com/t/update-gui-via-asynchronous-thread/9666) and the later.py script linked within. You’d want to look at the assignLater() function.  
As for timing, simply instantiate a new `java.lang.Date` object at suitable points, and subtract their raw milliseconds (via `.getTime()`) to yield a millisecond interval. If you need more precision, consider using `java.lang.System.nanoTime()`, but beware of poor multiprocessor implementations.

---

_[View the full topic](https://forum.inductiveautomation.com/t/return-something-from-an-invokeasync-invokelater-pair/16970)._
