Background
I have a powerbuilder program attempting to call a C# class that is exposed as com visible. The C# class is compiled at .Net 2.0, and is being called from PB 11.5.1.
C# Com Visible attributes
[ComVisible(true)]
[ClassInterface(ClassInterfaceType.AutoDual)]
[ProgId("MyID")]
When I compile my DLL (Any CPU architecture) I give it a strong key file. Does this key file need to be deployed with the DLL??? I do this because without it I cannot register the DLL in the GAC. I should note that i do not make the whole DLL com visible, just the classes I want in the COM.
I used regasm.exe to generate a reg file. The regasm.exe i used was located here: C:\Windows\Microsoft.NET\Framework\v2.0.50727
I did not use the /tlb flag, not sure if that should be used, or what it even does.
I don't understand whole lot in that registry file, I just notice PublicKeyToken = 908dbed57b0543c7
I then use gacutil to register the DLL in the GAC. I navigate to C:\windows\assembly and verify the DLL is in fact shown, and that the PublicKeyToken matches the one from the registry file.
gacutil /i "MyDLL.dll"
Finally I start Procmon and attempt to call the DLL, I don't see much in procmon that matches my DLL, I see it searching the registry and finding stuff, but thats about it. Nothing stands out to me anyways, and my program never actually gets to the DLL, which kinda feels like to me that its not finding stuff correctly in the registry/assembly.
This issue ONLY happens on a 64 bit Windows 7 PC. Haven't tried 64 bit Windows XP, I have my UAC all the way down, and I am admin to my PC. I have run out of ideas, so I decided to post here to see if anyone has some thoughts, or maybe has experienced a similar issue. I am sure I am misunderstanding something, any advice would be GREATLY appreciated.