带有导入DLL-s的ASP.NET网站

带有导入DLL-s的ASP.NET网站,asp.net,dll,Asp.net,Dll,我正在尝试调用文件.aspx.cs中的DLL函数,如下所示: [DllImport("the.dll")] private static extern bool theFunction(int width, int height); 以及: .dll文件位于C:\Windows\System32\inetsvr中 我的网站是一个具有读取和执行权限的应用程序 如果我在服务器上尝试File.exists.dll,它将返回true,因此dll位于服务器路径上 但是: 如果我尝试在localhost上

我正在尝试调用文件.aspx.cs中的DLL函数,如下所示:

[DllImport("the.dll")]
private static extern bool theFunction(int width, int height);
以及:

.dll文件位于C:\Windows\System32\inetsvr中 我的网站是一个具有读取和执行权限的应用程序 如果我在服务器上尝试File.exists.dll,它将返回true,因此dll位于服务器路径上 但是:

如果我尝试在localhost上运行该页面,一切正常 如果我尝试运行IIS服务器上上载的页面,页面将加载到无穷大。。。什么都没出现,什么都没发生!?然后IIS被阻止,我必须重新启动服务器。
我做错了什么?o_0检查IIS上的安全性和权限设置。 还可以尝试将dll放入bin文件夹