How to get specific text from Get Text Activity and put it in a variable?

Hello all!

I have a case where I need to use Get Text activity in order to get some data. But the problem is that Get Text activity takes whole text, and I can’t choose specific part of it.
g
In UiExplorer, I’m getting this result:
whole_text
So, what I need to do is to make two variables in which I will store these values.
Example:
car_manufacturer = AUDI
car_model = A1

Any ideas how could I make this happen?
Thanks in advance!

@bp777

Store output of Get Text activity in one string variable and then try below expressions to get required values from it.

                      firstString = getTextOutput.Split(" "c)(0)
                      secondString = getTextOutput.Split(" "c)(1)
3 Likes

firstString returns 1.AUDI, how could I prevent ordinal numbers before car manufacturer name?

Thanks in advance!

@bp777

Try below expression.

     firstString = getTextOutput.Split(" "c)(0).split("."c)(1)
2 Likes

Wow, amazing @lakshman!
Thank you so much!

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.