# Issue with return value from code cards in advanced flows

**URL:** <https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925>\
**Category:** Questions & Help\
**Tags:** homey-pro, advancedflow\
**Created:** [May 22, 2023, 10:51am UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925 "2023-05-22T10:51:12Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Alexander\_Bolotin](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/alexander_bolotin/32/72444_2.png) [@Alexander\_Bolotin](https://community.homey.app/u/Alexander_Bolotin)\
**Post date:** [May 22, 2023, 10:51am UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925/1 "2023-05-22T10:51:12Z")

</div>

If this turns out not being a howto question, but rather a bug report, please guide me right here!  
Image showing my code after test:

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/5/7/57124159dd22954e3aa0b3bef1a098823563e672.png)  
Image showing my trouble getting the recieving card to read the output of the code:  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/7/1793d4cfec049705dc2e55d4d0ceecb7147fa0fe.png)  
Note: The tag-name “klok12h” is kind of “glued” in this menu and reflects an earlier experiment of mine. The value (9) also made sense back then. I have restarted my Homey Pro but #klok12h pops up anyway!

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [May 22, 2023, 10:59am UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925/2 "2023-05-22T10:59:48Z")

</div>

Try running the flow once, then see if the “Result” tag (which contains the result of the script) appears.

---

<div class="post-metadata">

**Author:** ![Alexander\_Bolotin](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/alexander_bolotin/32/72444_2.png) [@Alexander\_Bolotin](https://community.homey.app/u/Alexander_Bolotin)\
**Post date:** [May 22, 2023, 11:08am UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925/3 "2023-05-22T11:08:30Z")

</div>

It has run many times, I use it to collect Excel data for my hourly power consumption (Swedish Excel doesn’t understand decimal points, only commas).

---

<div class="post-metadata">

**Author:** ![Alexander\_Bolotin](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/alexander_bolotin/32/72444_2.png) [@Alexander\_Bolotin](https://community.homey.app/u/Alexander_Bolotin)\
**Post date:** [May 22, 2023, 11:13am UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925/4 "2023-05-22T11:13:46Z")

</div>

Am I looking for it in the right place (under HomeyScript)?

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [May 22, 2023, 11:24am UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925/5 "2023-05-22T11:24:25Z")

</div>

Ah, no, it should be under “This Flow”:

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/0/10414ecd98b008edd613dc1879381787ff30a96a.png)

---

<div class="post-metadata">

**Author:** ![Alexander\_Bolotin](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/alexander_bolotin/32/72444_2.png) [@Alexander\_Bolotin](https://community.homey.app/u/Alexander_Bolotin)\
**Post date:** [May 22, 2023, 11:31am UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925/6 "2023-05-22T11:31:19Z")

</div>

Wow, thank you very much!!! (Now I can’t wait to the 14:00 run!)

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/4/244cef22bffa4fff030a0fa19d5479056a2f06aa.png)

The 14:00 run: (YAY!)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/c/1c3f526e23cefecbc0dddbf4f336df1581b5aa28.png)

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [May 22, 2023, 2:44pm UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925/7 "2023-05-22T14:44:52Z")

</div>

Just FYI: Working on a Format Number card in Better Logic Library right now for this kind of formatting (was still on the todo list).  
Hoping to finish it today.

---

<div class="post-metadata">

**Author:** ![Arie\_J\_Godschalk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/arie_j_godschalk/32/63027_2.png) [@Arie\_J\_Godschalk](https://community.homey.app/u/Arie_J_Godschalk)\
**Post date:** [May 22, 2023, 4:35pm UTC](https://community.homey.app/t/issue-with-return-value-from-code-cards-in-advanced-flows/80925/8 "2023-05-22T16:35:57Z")

</div>

Here, it’s in test now:

> [@\[APP\]\[Pro\] Better Logic Library - Just some better logic, variable and library management](https://community.homey.app/t/app-pro-better-logic-library-just-some-better-logic-variable-and-library-management/5568/331):
>
> I have just added a new flowcard, once it turns out to work as expected, it will also become available as a BLL expression method. Format [[number]] as decimal/currency/percent/unit card. This card has dynamic fields. You first pick if you want to format it as a decimal, currency, percentage or unit. Then other options becaume available in the 2 option-dropdown-arguments: Here an example of Currency, Dollar, with fullname, in Dutch: By default, the locale configured in the BLL app…

For you, this would be an easy card to use for this example:

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/4/b/4b563adcf490f7890e9d7f706f368e10eb881ffe.png)
