I am developing a UWP app for the HoloLens 2 with Unity. I want to write to a log file (to record user interactions), and then later retrieve that file. I do not want the user to have to select a file location.

The following code works on Desktop UWP app (output from same code and same Unity project). It does NOT work on the HoloLens, but instead throws an "Unauthorized" Exception. How can I write to a file on the HoloLens? And where can I find that file later?

```
public class Logger : MonoBehaviour
{
    StreamWriter logFileWriter;

    // Start is called before the first frame update
    void Start()
    {
        string fileName = "mydatalog.csv";

        // Creates a file in the default location:
        //      "build\bin\x64\Release\AppX" on Desktop
        this.logFileWriter = new StreamWriter(fileName);
    }

    void Update()
    {
        string record = // Stuff here...

        if (this.logFileWriter != null)
        {
            this.logFileWriter.WriteLine(record);
        }
    }
}

```