I have C ++ Exe in an application directory that contains the DLLs used by it. Now, for some testing purposes, I need to modify an existing DLL and use this instead of the original one. But in order not to modify the existing installation, I cannot back up the existing DLL and replace it with the changed one or move the existing one to another location. I also can not change Exe. Two DLLs must exist side by side. The only change should be that Exe should transparently load the modified DLL, which is in another folder, and not in the existing DLL, which is in the same folder as Exe. Is there an elegant way to do this?
I looked through some MSDN articles but couldn't find a way to do this. The solution should work on Windows XP and higher.
source share