I'm trying to export some data to a txt file, but it doesn't work since I get unauthorized exception.
I tried running visual studio as admin, but it didn't work
This is the code I have:
TextWriter txt = new StreamWriter(path);
for (int i = 0; i < Movies.Count; i++)
{
txt.WriteLine(Movies[i].title);
}
txt.Close();
The path is correct