I have a WinForm application developed in C# which looks for a file in my local drive and if it doesn't find it then creates it else add some text in the file and then read it.
How can I synchronize this if I run the two instances of my app from two different folders on the same machine?
I want the other instance not to interrupt when the first instance is working on the file. Please note that as both are the instances of the same application, they work on same target folder to read-write the file.
Is there any threading technique needs to be implemented?