# Why does function node not write the value to my global?

**URL:** <https://discourse.nodered.org/t/why-does-function-node-not-write-the-value-to-my-global/86852>\
**Category:** General\
**Tags:** function-node\
**Created:** [29 March 2024 13:12 UTC](https://discourse.nodered.org/t/why-does-function-node-not-write-the-value-to-my-global/86852 "2024-03-29T13:12:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![novski](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/novski/32/23243_2.png) [@novski](https://discourse.nodered.org/u/novski)\
**Post date:** [29 March 2024 13:12 UTC](https://discourse.nodered.org/t/why-does-function-node-not-write-the-value-to-my-global/86852/1 "2024-03-29T13:12:25Z")

</div>

Why does that value not been read? Its sets value name not the value value...

 ![Bildschirmfoto 2024-03-29 um 14.09.15](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/5/85996ceeb4285adbea0cdd0755fac54c4791c858.png)

---

<div class="post-metadata">

**Author:** ![E1cid](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/e1cid/32/77971_2.png) [@E1cid](https://discourse.nodered.org/u/E1cid)\
**Post date:** [29 March 2024 13:22 UTC](https://discourse.nodered.org/t/why-does-function-node-not-write-the-value-to-my-global/86852/2 "2024-03-29T13:22:58Z")

</div>

Try `[room]: {` to let JS know it is a var not a property name.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [12 April 2024 13:23 UTC](https://discourse.nodered.org/t/why-does-function-node-not-write-the-value-to-my-global/86852/3 "2024-04-12T13:23:03Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
