1

I have a classic ASP website that I am trying add functionality to (and speed it up). To do this I have written a COM visible dll (.NET Framework 4). The website is hosted on Windows Server 2008 R2, 64bit, IIS 7.5. I'm registering my dll with regasm and gacutil. So far so good, everything works quite nicely and I can successfully call my dll from vbscript. As long as I'm only referencing .NET namespaces it works like a charm.

My problem is that when I want to add a new reference to a third party .NET dll (in this case active PDF toolkit APToolKitNET.dll). In the classic asp (vbscript), if I call a method in my dll that references the third party dll I get the following error:

Could not load file or assembly "APToolKitNTE, Version=5.4.2.1403, Culture=neutral, PulblicKeyToken=e43.....' or one of its dependencies

After a lot of searching around and trying many things I'm not winning. As a test I've tried writing a quick little asp.net site to do call the same method and it works fine.

John Saunders
  • 160,644
  • 26
  • 247
  • 397
micgor
  • 11
  • 4
  • This should help: http://stackoverflow.com/questions/9503429/filenotfoundexception-when-loading-dll – 500 - Internal Server Error Mar 05 '13 at 00:56
  • Maybe 64 vs. 32 bit issue. – Shadow The GPT Wizard Mar 05 '13 at 09:07
  • @500-InternalServerError: The blog article linked in the post you mention was quite helpful without giving exactly the answer. What is interesting for this problem: Classic ASP site references DLL A which in turn references DLL B, this scenario gives the error. However: ASP.NET website references DLL A which in turn references DLL B, this scenario works fine. Where: DLL A is .NET4 and COM visible, DLL B is .NET2 but not COM visible. I have solved the problem was solved by adding DLL B to the GAC with gacutil.exe. Although I don’t understand why since DLL B isn't being referenced via COM. – micgor Mar 05 '13 at 19:58

0 Answers0