• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 865
  • Last Modified:

ISAPI DLL calling Net DLL on IIS 7

I have an ISAPI DLL written in Delphi 6 which calls a .Net DLL written in C#. I have it installed and running fine on a Windows 2003 Server running IIS6, however, in the new test environment running Windows 2008 server and IIS 7 I get an OLE exception in that it can't find the .net DLL. The .Net DLL is installed on both systems the same; The DLL is in the same folder off the C drive and was registered using REGASM.exe. In addition, the DLL was installed in the GAC (drag n drop to the Windows\Assembly folder). Were there some security changes with Server 2008 and/or IIS 7 that would prevent this setup (same for both Windows 2003 and Windows 2008 environments) to work?  Thanks.
0
bmichene
Asked:
bmichene
  • 5
  • 2
1 Solution
 
cj_1969Commented:
Could be a simple path problem ... check your path variable on the old machine and see if the directory of the second DLL is in there, if it is then add the path to the path variable on the new server.

0
 
bmicheneAuthor Commented:
The directory is not in the path of either machine.  I even tried moving the Net DLL to a folder in the path with no difference noted.  When an assembly is added to the GAC, does it require a reboot for the services to recognize the new assemblies?
0
 
cj_1969Commented:
According to this page drag-n-drop des not work for registering a DLL in the GAC.
You have to run a command line to do it ...
2- Type in this command to register or install the DLL file "mylib.dll"
gacutil /i c:\myfiles\mylib.dll
3- Now go to the GAC folder (c:\windows\assembly) and look for the DLL file you registered using using the command in Step 2. The DLL file should now appear in the GAC folder.

There is no reference as to whether this is for 2003 or 2008 so its worth a try.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
cj_1969Commented:
You can do drag-n-drop but it requires an additional app "The Assembly Cache Viewer".

Here is a reference to working with the GAC ... http://msdn.microsoft.com/en-us/magazine/cc164080.aspx
0
 
cj_1969Commented:
According to this page ... http://social.msdn.microsoft.com/Forums/en-US/netfxsetup/thread/1c3ab849-84a0-4eb7-8c3b-b01fbca825a3 ... if you start the Windows explorer pointing the assemblies directory then drag-n-drop will work.  

"UPDATE: I discovered that it does work to create a shortcut to Windows Explorer which includes the path to the GAC (Target: %SystemRoot%\explorer.exe C:\Windows\assembly), which you can then invoke via Right-click, Run as Administrator. I put one on my desktop and labeled it "GAC" for quick access."
0
 
bmicheneAuthor Commented:
I've tried all the suggestions above and I've come to the conclusion that it has to be what rights/privileges IIS7 has to the folder where the .NET DLL/Assembly is located.  What I don't know is what privileges to give what account to that folder.
0
 
cj_1969Commented:
Try granting the Network Service account on the local machine access to the directory.
0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

  • 5
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now