I have a text file(.txt) like this
Dialogue: 0,0:00:01.99,0:00:03.84,Default,,0000,0000,0000,,Up you go!
Dialogue: 0,0:00:03.84,0:00:06.31,Default,,0000,0000,0000,,And, again!
Dialogue: 0,0:01:42.92,0:01:44.91,Default,,0000,0000,0000,,Hang on a minute.
I want to insert "{" and "}" into that file like this
Dialogue: 0,0:00:01.99,0:00:03.84,Default,,0000,0000,0000,,{Up you go!}
Dialogue: 0,0:00:03.84,0:00:06.31,Default,,0000,0000,0000,,{And, again!}
Dialogue: 0,0:01:42.92,0:01:44.91,Default,,0000,0000,0000,,{Hang on a minute.}
I mananed to insert "}" to the last using these code
String path = openFileDialog1.FileName;
List<string> line = new List<string>();
StreamReader sr = new StreamReader(path);
StringBuilder sb = new StringBuilder();
String lines;
while ((lines = sr.ReadLine()) != null)
{
line.Add(lines+"}");
}
foreach (string s in line)
{
sb.AppendLine(s);
}
I want to insert "{" right after "0000,," . Sorry for my Eng and Thank you for your help.