I have a string that looks something like this

`Say_Hi~~~Say_Opt1~~Say_Opt3~~~Say_Opt6~~~Say_Opt9~~Say_GoodBye`

It has 16 '~' dividing it into 17 "sections". In section number 5, I need to insert `Say_Opt5`.

`Say_Hi~~~Say_Opt1~~Say_Opt3~~Say_Opt5~Say_Opt6~~~Say_Opt9~~Say_GoodBye`

So I need to be able to take a string, and a position, and isert the string into the position specified. I tried using a regex but im not entire sure how matches work.

```
 string baseString = "Say_Hi~~~Say_Opt1~~Say_Opt3~~~Say_Opt6~~~Say_Opt9~~Say_GoodBye";

var newString = new Regex("~").Replace(baseString, "Say_Opt5", 7);

```

Also, there may already be an Option 5, so I need to replace the old option5 with the new option 5. Such as replacing

`Say_Hi~~~Say_Opt1~~Say_Opt3~~Say_Opt5~Say_Opt6~~~Say_Opt9~~Say_GoodBye`

with

`Say_Hi~~~Say_Opt1~~Say_Opt3~~Say_Opt5_Custom~Say_Opt6~~~Say_Opt9~~Say_GoodBye`