Dynamic data in text boxes must be printable as text

Hi! Going nuts here. Trying to read in some text to my database but getting an error “Dynamic data in text boxes must be printable as text, this is a element.”

My text box is just text, nothing dynamic about it. My database item is a Text type of field. The ‘More’ button doesn’t give me any useful options.

This is the last piece of a very (very) long chain of development and I am snagged, would really appreciate some help, hopefully it is something silly I am missing.

Thanks,
Steve.


Text elements are just for displaying texts… they don’t hold any usable value in Bubble, so you can’t refer to the text in a text element elsewhere…

You can only refer to the data source the text is referring to (assuming it’s dynamic)…

In your case, you say the text is not dynamic, just a static text… so you can just enter the text again in your field value (no need to refer to anything else if it’s static)…

Or, to avoid doing things twice (which is always a good idea), set a custom state with the static text, then refer to that in both the text element and the field value in your workflow.

1 Like

Thanks Adam!! The real text I want to bring in is actually dynamic but I simplified it down to pure text to try to clear the error (without joy).

I hadn’t thought of using Custom States - will try that now and see if I can get it to work. Fingers crossed, very happy to get another direction to try, thanks a million!

If the actual text is dynamic then just use the same data source to set the field value in your workflow as you use to display the text…

Or you can still use a custom state, you just can’t set a default value dynamically, so you’ll have to set it via a workflow, which may or may not be easier than just referring to the text’s data source again…

1 Like

Hey. Yep hitting a wall with the custom states.

The problem is that I have two dynamic texts that I want to read in, and they are both three-way conditional, it would mean creating a lot of conditional workflows.

The heart of the issue is so frustratingly simple, I have a calculated number (minutes) via a calculator plugin but I need to read that in as two digit text (e.g. a result of 3 becomes 03, result of 0 becomes 00, result of 13 stays 13).

I can get the right expression result in my calculator plugin but then it pares it down to single digits in the text result. Argh!! Tried to use the text box as a workaround but hit the snag in my OP.

I think I’ll just have to replicate the three conditions (X2) with six ‘Update Thing, only when…’ workflow steps (situated after the ‘Create thing’ step).

Wow ‘simple’ things can get messy fast haha!

You can do that without any conditions…

Just set the value to: (calc mile min's number Result - Calc int mile min's number Result) x 60: rounded to 0: < 10: format as text

For True use: 0(calc mile min's number Result - Calc int mile min's number Result) x 60: rounded to 0
For False use: (calc mile min's number Result - Calc int mile min's number Result) x 60: rounded to 0

I’m not sure what your third condition (when the value is 0) is for? I don’t see that as necessary, that’s covered by the < 10

You can do the same thing for both parts of your text, so only a single workflow action is required, and no ‘only when’ conditions are needed.

You could use a custom state to make things a little cleaner in the workflow…

i.e. in step 1, set the 2 custom state values to the calculated numerical values… then just refer to those values in the rest of the workflow instead of building out the full expressions again…

1 Like

Hi Adam,

Thank you, thank you, thank you.

Your solution above worked perfectly, and you have taught a man to fish :wink:
I wasn’t aware of the boolean functionality at all, that is a great tool I now have in my kit, so useful.

Really appreciate you taking the time to share this knowledge.

Cheers,
Steve.

Yep, it’s a very handy feature and can save a lot of work…

Glad to have helped :slight_smile:

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.