cancel
Showing results for 
Search instead for 
Did you mean: 

external DLL reference question

Walter.Koller
Level 11

Hello,

I am posting here because the issue came up when working with MSAL that needs external DLL.

When we copy the Microsoft.Identity.Client.dll file to the folder where automate.exe is located it works.

When we copy the dll to another folder Blue Prism will bring up an error message because of compile error. This make sense as Blue Prism does not know where this dll is.

We can resolve the compile error by qualifying the full path to the dll. I would assume Blue Prism find the dll, can resolve dependencies and namespaces as there is no compile error.  

Although BP seems to be fine with the reference to the dll we get this error at runtime:

Internal : Could not execute code stage because exception thrown by code stage: Could not load file or assembly 'Microsoft.Identity.Client, Version=4.42.1.0, Culture=neutral, PublicKeyToken=0a613f4dd989e8ae' or one of its dependencies. The system cannot find the file specified.

 

Internet provides me solutions for C# projects but not how to resolve this problem for compiled executables like Blue Prism. 

I just created similar situations with Microsoft.Office.Interop.Outlook.dll and it does not matter where this dll is located, next to automate.exe or some other folder as long as the location is fully qualified.

What are we missing to make Microsoft.Identity.Client.dll work when located in a folder separate to automate.exe?

 

Thanks a lot,

 Walter

1 REPLY 1

GeoffHirst
Staff
Staff

Hi @Walter.Koller 

Thank you for being a SS&C Blue Prism customer, and for using Blue Prism.

This is a frustrating issue, especially as you think everything should be in order.

When I see this, the first thing I look for is the actual version of the file the (4.42.1.0 bit) on the file that you have referenced to Blue Prism. My thoughts are that the file you have is older or, more likely, more recent than the one being requested. It's a whole new kind of 'dll hell'. 

So, please, give this a look over and see if the versions are different, if not, we do have a referencing issue that isn't working out, if they are different, you should be able to find the exact version you need on nuget.org.

Please come back to me if you continue to have issues and we will see what else we can do.

regards

Geoff Hirst Senior DX Engineer - Digital Exchange - EMEA SS&C Blue Prism