LINK: fatal error LNK1168: cannot open xxxxx for writing
In this case, it is usually that the last program occupation was not completely closed when VS was performing image reading and writing. What you
need to do at this time is to open the task manager, find the process, kill it, and compile again, and you will find that the compilation passes.
The above is the solution. Perhaps it is not only the image operation that appears. For example, the MFC interface operation will also encounter this situation. The solution is unified.