My personal vote for a capable logging library goes to SmartInspect because in the end it’s not just about writing a log file but also reading it later and depending on the amount you want more than a txt file with walls of text but a capable viewer with filter and search functionality.
@Malcolm You might want to look into some SEO because it requires some significant effort to even discover the product page.
That should be ok, although in it’s quite often the case that the roaming profile folder is on a network drive - so I would log to AppData\Local if possible.
What is the missing DLL? I have used SmartInspect for many years, and don’t recall any DLLs associated with it. This was one of the reasons I like it so much.
We get sporadic “file in use by another process” errors in our apps that are file heavily (downloading, unzipping, parsing, zipping thousands of files) but never for our log file. It is always caused by two things:
Anti-virus (we ask customers to add an exception/allowed/trust for our data folders to their AV app)
Windows search indexer (we ask customers to consider disabling the indexing of file contents, primarily on servers)
So if some multi-threading/dup log open issue is ruled out then look at these.
Obviously, things like having a file open in Excel or some other app that denies sharing will cause it too but that’s an easy one to identify and solve.
I should look at SmartInspect. We deal with some pretty large log and other text files and use klogg. A great simple viewer that handles huge files with very fast search, manual marking and auto filtering and highlighting, follow mode, etc. Easy to mark separate lines from different parts of the file to put them into a common view for comparing.