Get string between strings in c# -
i trying string between same strings:
the texts starts here ** string ** other text ongoing here.....
i wondering how string between stars. should should use regex or other functions?
you can try split
:
string source = "the texts starts here** string **some other text ongoing here....."; // 3: need 3 chunks , we'll take middle (1) 1 string result = source.split(new string[] { "**" }, 3, stringsplitoptions.none)[1];
Comments
Post a Comment