Text function in .NET (as SEARCH/FIND in Excel)


#1

Hi,

Do you know any function in UiPath that would return the number of the first found character (e.g. space) within the specified string (reading left to right). As the function SEARCH/FIND do in Excel.

I have strings where the first word needs to be extracted but the length of it can differ in each case.

I can do it with the Split method but I hope that it can be done using only one function.

Thank you!


#2

Hello,

Not sure what your asking, but what if you trim the spaces on the ends then just split by space?
str.Trim.Split(" "(0))(0)


#3

String.IndexOf