In C#: If I want to create a message like this: \"Hi We have these flights for you: Flight A,B,C,D. Which one do you want\"
where just the section i
1 You can use string.Replace method
string.Replace
var sample = "testtesttesttest#replace#testtesttest"; var result = sample.Replace("#replace#", yourValue);
2 You can also use string.Format
string.Format
var result = string.Format("your right part {0} Your left Part", yourValue);
3 You can use Regex class