Hello again,
I do apologise about this question, probably the answer does already exist, however im not able to find it on the Forum.
I would like to know if its possible to have a sort of "conditional statement, something like I was using in dart/flutter ; example : variable ? do_this_if_true : do_something_else
However Id like to do it when Im assigning a value on the “Change field property”
Example :
Would it be possible to say : activemessage =yes ? if it is selected no : no if it is selected yes?
on the same “space” where u assign the value?
Thank you for your help.
Nik
Would it be possible to say : activemessage =yes ? if it is selected no : no if it is selected yes?
Indeed… just use:
activatemessage = This User's activatemessage is no
1 Like
Thank you, indeed it does work. But now the problem is that I clearly have not understood what “this user” refers to. (So it will loop through each’s user activate message… )
Moreover I dont understand why it does assign the “opposite yes or no” value to the variable , as i m not able to “read” a if condition in that “this user’s activatemessage is no/yes”
Thank you very much for your help,
Maybe I got it ? , Cos it is checking if the “activatemssage is No?” the answer is yes, then assigns yes… or viceversa
Right?
And with regards of “this User” I was trying to look for something like “for each user’s activatemessage…”
Thank you for your time.
Nik
1 Like
I clearly have not understood what “this user” refers to.
You’re making changes to a list of Users… so ‘This User’ refers to the specific User in the list of Users that the changes are being made on.
Moreover I don’t understand why it does assign the “opposite yes or no” value to the variable
When you set a yes/no value with a dynamic statement in Bubble, you’re effectively telling Bubble when to set the value to ‘yes’.
So, were you to use (for example):
activatemessage = Current User Is Logged In
That basically means “set the activatemesage” value to Yes when the Current User is Logged In.
So, the activatemessage field would be set to Yes if the user was logged in, and No if the user was logged out.
In the case of referring to an ‘existing value is no’, you’re telling it to set the new value to Yes if the Old value is No (and vice versa)…
So, by using:
activatemessage = This User's activatemessage is no
This User’s activatemessage field will be set to Yes when their existing activatemessage field value is No (and vice versa).
3 Likes
Yes, I now understand.
I need also to review the concepts in regards Current User/ This User as I do often misunderstand them.
Once again , thank you for your help and time
Nik