I have a big word inside a string. Example White wine extra offer.
I want to take 'White' in first line and 'wine extra offer in second. using this code below:
string value="White wine extra offer";
value = value.Split(' ').FirstOrDefault() + ' ' + Environment.NewLine + value.Split(' ').LastOrDefault();
I'm getting in output White/r offer. I'm taking the word after last space and no after first.