Hi there,
My macro uses a function in an external DLL declared on top like:
Declare Function Calculate Lib "CalculationsLib.dll" (ByVal param1 As Integer, ByVal param2 As String...)
The DLL library is in the same path as the excel document. Then the instruction in the macro is like:
result = Calculate(..)
When I launch the macro, this instruction fails telling the lib is not found (error number 53)
Well, an easy solution is to define my folder in "Trusted Locations" in Excel security options, or even put the files in an already existing trusted location. Then the macro launches the function without any error and get the result.
But the problem is when I've closed the Excel application and started again. I take the same error and have to remove the path from the trusted locations and put it on again to work with the lib.
Any help?
Thanks
Pepe
My macro uses a function in an external DLL declared on top like:
Declare Function Calculate Lib "CalculationsLib.dll" (ByVal param1 As Integer, ByVal param2 As String...)
The DLL library is in the same path as the excel document. Then the instruction in the macro is like:
result = Calculate(..)
When I launch the macro, this instruction fails telling the lib is not found (error number 53)
Well, an easy solution is to define my folder in "Trusted Locations" in Excel security options, or even put the files in an already existing trusted location. Then the macro launches the function without any error and get the result.
But the problem is when I've closed the Excel application and started again. I take the same error and have to remove the path from the trusted locations and put it on again to work with the lib.
Any help?
Thanks
Pepe