I am new to C#, and I have a project which I have a built as a class library to check for updates before the app starts.
For the program to run this dll file should be in the same directory where the main app is, I want to change the directory of this dll file to be in a sub folder.
I have tried to change app.config
file, but it started to cause runtime errors.
Is this possible?
If you import Updater Project into your main project, MsBuild compiles both of them together. And you won't need to deal with such complexities.
Honestly, ı couldn't understand what you tried to do. But above approach would solve your issue.
Refer to this article:
also this is useful: load a .NET assembly at runtime
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.