Bug expression true?

251 views
Skip to first unread message

tomm...@gmail.com

unread,
Apr 24, 2017, 7:11:11 PM4/24/17
to Automate
Hi i'm returning a variable from block "dialog choice?" that return on a variable output my_variable 0 or 1! Then after the yes side I put a block "expression true?" Then i put = my_variable=1
The response is always false! What's happened?
How can i have a true or false? It's look like so simple

Henrik "The Developer" Lindqvist

unread,
Apr 24, 2017, 7:50:05 PM4/24/17
to Automate, tomm...@gmail.com
Note! The a selected indices/keys output variable is assigned an array even when only a single choice is possible. 
To get the first or single choice index/key use the subscript, i.e: selected[0] or choices[selected[0]].

http://llamalab.com/automate/doc/block/dialog_choice.html

Thomas Melou

unread,
Apr 25, 2017, 3:27:29 AM4/25/17
to Henrik The Developer Lindqvist, Automate
Thank you! BUT ...
I used the array my_variable [0] in expression true but it's work only as true or false without real compare! I can't check if =my_variable [0]=1, i'm oblidge just to put =my_variable [0] so if i will compare to a 2 or 3 i couldn't do it


Henrik "The Developer" Lindqvist

unread,
Apr 25, 2017, 7:46:23 AM4/25/17
to Automate, henrik.l...@gmail.com, tomm...@gmail.com
First choice selected:
my_variable[0] = 0

Second choice selected:
my_variable[0] = 1

etc...

arnova...@hotmail.com

unread,
Apr 25, 2017, 6:25:28 PM4/25/17
to Automate
Hi,

I am also having trouble with an if block.

I am making a flow that pauses on 4 parallel when blocks. To avoid duplicate paused fibers I am try in if expression block.
I keep having more parallel when blocks poping up.
Block 180 and 181 loop twice and I dont understand why.

https://www.dropbox.com/s/zm44x1kbrje73jx/WiBlue%20Control%202.0.pdf?dl=0
https://www.dropbox.com/s/qxtex9oquasq6v5/flo.txt?dl=0

I hope I am mistaking.

Henrik "The Developer" Lindqvist

unread,
Apr 25, 2017, 7:25:10 PM4/25/17
to Automate, arnova...@hotmail.com
A Fork that reconnects back to the main fiber, the first Variable set block in your flow, will create more and more fibers, that's expected. Please read:
http://llamalab.com/automate/doc/block/fork.html

As for the potential Expression true block issue, please make a minimal flow reproducing the issue.

arnova...@hotmail.com

unread,
Apr 26, 2017, 4:30:30 PM4/26/17
to Automate
Hi,

reading the fork explanaition again made me realise why the if block wasn't working!

https://www.dropbox.com/s/smgbatcgsq0qz7j/flow.pdf?dl=0

Thx for the help, app and all the forum reply's!

bezar...@gmail.com

unread,
Jun 29, 2018, 7:27:52 AM6/29/18
to Automate
Hi,
I have a trouble with the expression true? Block that is always on false.
content://com.llamalab.automate.provider/flows/6/statements/141
Block 182
Message has been deleted

bezar...@gmail.com

unread,
Jun 29, 2018, 7:33:29 AM6/29/18
to Automate

Henrik "The Developer" Lindqvist

unread,
Jun 29, 2018, 2:48:24 PM6/29/18
to Automate
Try logging, i.e. the Log append block, the source variable, to ensure it hold the value you're expecting.

bezar...@gmail.com

unread,
Jun 30, 2018, 11:32:24 AM6/30/18
to Automate
I'm so stupid... I have written "source" instead of "source_liste". But now, I have an other problem: my program doesn't work when I want to move a file in my SD card but it's working when I move a file from internal storage to internal storage. Test it please! https://drive.google.com/file/d/1dfZCVZY5yblEkZTCNhoq1OhdM_tmdco-/view?usp=drivesdk

Henrik "The Developer" Lindqvist

unread,
Jun 30, 2018, 2:29:21 PM6/30/18
to Automate
Ensure to grant access to SD card in Automate settings, External storage.

bezar...@gmail.com

unread,
Jun 30, 2018, 5:39:44 PM6/30/18
to Automate
Thank you very much! It works!
Reply all
Reply to author
Forward
0 new messages