Use custom states to use reusable element across Data Types

I’m having some trouble using custom states to make my reusable element work across two data types, Tasks and Subtasks.

Currently the reusable is of Type Task. Here’s my attempt at using custom states to toggle between Task and Subtask, so I can use it on both types within groups/elements.


Not sure exactly where I’m going wrong to make the Value invalid… Anyone have any ideas? Thanks!

Because you can not set a custom state that of a one type of data using values that are of a different type of data.

Think about data types as blocks of shapes (the ones babies learn and play with - colorful, different shapes like stars and squares and circles), and think about the custom state as the cut out hole to fit the block into. You can not fit a circle block into a cut out for a square and you can not fit a square block into a cut out for a circle.

What is the use case for the need to have two different data types used in the reusable? It is not an impossible feat, but details on how you intend to use the different data types, can help others point you in the direction of how to achieve your end result.

1 Like

That was my understanding going into it until I came across this post: Changing Reusable Elements Content Type Dynamically.

The use case is to have an Assignee Dropdown (reusable element) on a Task, and on that task’s Subtask also. They are obviously different data types and obviously a task and subtask can have different assignees also. I’m trying to be mindful of the speed of my app, but I think it might be best to just create another reusable element.

I believe you misunderstood that post…it doesn’t talk about changing the content type (at least the experienced users who were replying to the posts request for help). It talked about the use of custom states (plural) in which you have more than one custom state, one each for each of the different data types you want the reusable to be used for.

1 Like

Ah okay I see. In this case I’ll just create another reusable element. Thanks @boston85719 for shedding some light on it all.

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