Fixed text in Text elements

Hello,

In my app I have a text field.
I’ve put some intial content in it but by default it’s not “fixed”, I would like to make sure that the user cannot edit or delete this part of the string.

For example:
The content of my text field would look like this:

AB - 123456

"AB - " should be fixed and
“123456” should be editable by the user

How can I achieve this?
Thanks

1 Like

There are a number of ways you could go about it, but here are two that immediately come to my mind.

If you don’t need to show the "AB - " part to the user, you could add that part (as a prefix, of course… just can’t bring myself to use “prepend” in a sentence) to the value of the input field on the back end during the workflow.

If you want to show the "AB - " part to the user, then I would probably put it in a separate input field that is directly in front of the input field the user can edit, and set the "AB - " input field to disabled. Then, I would combine its value with the value from the other input field during the workflow.

Just food for thought… hope it helps.

Best…
Mike

1 Like