Regarding issue with the dll

Actually, I see the root of your exception is UIPath invoking code. I suspect the solution to your problem is determining how to properly register external dll’s for UIPath to be able to invoke that code. Ie, it looks more like a UIPath configuration issue than a csproj issue.