Possible to store output value as a combination of other variables?

Hey so this is a tough one.

I am using a get text activity and I am currently storing it as ExpCurrentCommission which works obviously. However, I have another variable named DomCurrentCommission.

Is it possible to have variables directly in the output value? So the output value would be stored in either ExpCurrentCommission or DomCurrentCommission? It would look like ExporDom + CurrentCommission? Where ExporDom would be another variable that would be equal to Exp or Dom.

Is this possible? IT would save me the the hassle of having two seperate get text activities and multiple If statements.

Hi @Asanka,
There is datatable type where you can keep different types of variables inside.

Sorry I think there was a misunderstanding. This is what I meant.

Is it possible to enter variables in the output value of a get text activity?

No it’s not possible like that. Activity is programmed to have dedicated form of output type and shape. That’s why you have “Assign” activity where you can for example combine data of same type like in this example:

Yes i get what you are saying. I guess the issue is, in your example i’m trying to change the variable name, “value”, not the actual “the button text is” I want to save the text in one variable if one situation exisits and save the text in another variable if another sitution exisits. Not possible my way eh? I need to use an if statement and two get text activities I guess?

Exactly. IF statement is the solution here :slight_smile:

1 Like

Darn! Ha well it looks like i have to create quite a few of them then. I was really hoping it was possible but I had my doubts.

Thanks for letting me know!

or…
if you are familiar with vb.net or c# (depends what your project is using) you can use .net form of if statement in assign activity directly (which will make less mess in project) :slight_smile:

Is that right? If possible, could you give me a rudamentary example of using vb.net to do that?
Essentially, what I want is my variable output to be either ExpCurrentCommission or DomCurrentCommision. The Exp/Dom would be the variable. I would assign that at the top of my workflow. How would I use a vb.net if statement in the output value section for that?

What you say is my primary concern, I hate messy projects :slight_smile:

Oh you can only do that in an assign activity right? We can’t do it in an actual output value field eh?

Yup. As I mentioned output is let’s say “protected” it can handle only programmed output way.
Here is example of what I mentioned. Still saves some space :smiley:

1 Like

Hey thanks for this.
Darn i don’t think it will work for me though as I need it to save the output value to a specific variable based on the situation (exp or dom) so i guess I will have to use a bunch of the same get text activities with different output values

1 Like