How can I delete a file in C# e.g. C:\\test.txt, although apply the same kind of method like in batch files e.g.
C:\\test.txt
if exist \"C:\\test.txt\" dele
if (File.Exists(path)) { File.Delete(path); }