i have two DLLs which are mostly identical but which different versions.
I want to load both DLL files and store the link to the DLLs as variable in an Hash Table. During runtime i want to call function dynamically from the first or the second DLL file (depending on a variable in a given object). Is that possible with Powershell?
It’s maybe possible but it’s going to be really, really tricky. This isn’t “PowerShell” you’re dealing with, it’s .NET Framework’s Interop layer, which s complex. Suggest doing a Google for “interior import specific dll path” and see if you find something that looks useful for you (there were several promising hits when I just tried). You may find it easier to do this in C#, which is a little “closer” to .NET’s core than PowerShell.