I might use 「System.IO.File.AppendAllLines」 or 「FileStream」 to write the logs into the text file.
But it doesn't work when there are too much users in the meantime.
I found out that the text file would be locked because of too many users trying to write it.
So my coworker suggest me to design a static class, then implement a static method to write the log.
Even there are many users call this method at the same time, it would be called in sequence.
Then the text file won't be locked.
I am just curious whether this saying is correct?
This post has been edited by JackOfAllTrades: 25 July 2013 - 09:21 AM
Reason for edit:: Removed large font