Hello everyone,
I would like to extract each word in the sentence occurring after the blank space.
Example sentence :
" Hello everyone, this is a pleasant afternoon"
Regards
Pranav Sundar
Hello everyone,
I would like to extract each word in the sentence occurring after the blank space.
Example sentence :
" Hello everyone, this is a pleasant afternoon"
Regards
Pranav Sundar
Try this syntax:
sentence = " Hello everyone, this is a pleasant afternoon"
wordsArray = sentence.Split(" "c).Skip(1).ToArray()

sentence = " Hello everyone, this is a pleasant afternoon"
wordsArray = String.Join(Environment.NewLine, sentenceSplit(" "c).Skip(1))

Hope it helps!!
You can use the Split function to split the each word with space. Use the below linq expression to extract each word after space and store in a List of String datatype variable called List_Items.
- Assign -> Input = " Hello everyone, this is a pleasant afternoon"
- Assign -> List_Items = Input.Split(" "c).Where(Function(X) Not(String.IsNullOrEmpty(X) Or String.IsNullOrWhiteSpace(X))).ToList()
Then use for each activity to iterate the each item in the List_Items variable.
Check the below workflow for better understanding,
Hope it helps!!
Thank you everyone for the solution.
Regards
Pranav Sundar
@Pranav_Sundar
Kindly mark as solution so the loop closes
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.