I use the File.WriteAllLines() method in my project. The txt file is to be synced to a remote server (via another application, Autodesk Docs in my case) upon Save action.
I am not sure why, but using WriteAllLines does not trigger syncing of the file, while opening it and performing a save manually does trigger the sync.
I suspect it's maybe due to WriteAllLines deleting the existing file and creating a new one instead of overwriting the data inside the file...?
Is there a way to overwrite by deleting the existing the data in the file instead of deleting the existing file and creating a new file?
Am I even right about WriteAllLines deleting the existing file and recreating it?