I think this answer is easier and faster:
public static void WriteToFile(string Path, string Text)
{
string content = File.ReadAllText(Path);
content = Text + "\n" + content;
File.WriteAllText(Path, content);
}
Then you can call it:
WriteToFile("yourfilepath", "A,B,C");