String manupulation

hii…
i have a string like "Hey team, My name is XYZ.

I want to extract the part between the “,”(comma) and the full stop.

Use
Var=“Hey team, My name is XYZ.”
Var.Split({","},StringSplitOption.None)(1).Trim.Split({"."},StringSplitOption.None)(0)

1 Like

Hi @karan_kapoor1

You can also try this.

Variable = “Hey team, My name is XYZ.”

System.Text.RegularExpressions.Regex.Match(Variable,"(?<=,)([\S\s]*)(?=.)").Value.Trim

1 Like

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