1
I am working with a Dll from Itaú bank(itauCripto.dll), the documentation requires it to be registered locally on the machine running the application. So I put the Dll inside the folder
%systemroot% Syswow64\
and registered it by CMD as administrator using
%systemroot% Syswow64 regsvr32 itaucripto.dll
I added her reference within my project in Visual Studio 2017 as COM Reference and used it normally within the project.
The fact is that on my machine is running correctly without any problem, but when I apply this change to the production server the application does not find the Dll.
The part of the record I did exactly the same thing I described above on the production server but when I publish the project and game on the production server it does not find the reference.
I noticed that although when I select the Dll in the Add Reference panel it is pointing to the folder %systemroot% Syswow64 in my project the reference is pointing to the bin folder of the project (Webapplication obj Debug Interop.Itaucripto.dll).
I don’t know if when the visual studio publishes the project it is getting lost in this way.
Can anyone say what is wrong or how I can make that path relative?
Your IIS application pool is running at 64bits tbm?
– Bruno Warmling
This in 64bits, was disabled to run in 32bits, I changed now to true the configuration and I will test, because I’m almost sure that the dll is 32 bits. As I am using iis express on my machine I believe it is not a problem, but as on the server the settings are different can be a way.
– Ricardo Cardoso
If it is 32bit, there is a difference in the record... It would have to be done by the directory
%systemroot%\System32
.– Bruno Warmling
@Bruno I think the problem was actually related to the platform. I changed the pool to allow 32bits, but also changed the property of the project reference to Embed Interop Types = False. This caused the Dll to be published along with the project. It worked perfectly, I will publish the full answer to help anyone who needs it.
– Ricardo Cardoso