This sounds like a "caspol" issue. Network shares like \\localhost\program\
get reduced trust. Interestingly, from (some time ago), named shares actually get more trust - so one simple option is to map, say, z:
as \\localhost\program
, and access z:\prog.exe
- you might find that this makes it work. Beyond that, the options are:
- caspol changes to the each client machine
- ClickOnce
of those, the latter is simpler. Then you simply run the ClickOnce application (rather than the .exe) - ClickOnce then basically makes it work. The user will, IIRC, need to click an "ok" the first time they run the application, but that's about it. You would need to ensure that the external dll is known the the ClickOnce deployment, i.e. it is in the project and marked to be shipped.