在全局程序集缓存(GAC)中注册应用程序DLL的问题 [英] Problem with Registering Application DLLs in the Global Assembly Cache (GAC)

查看:90
本文介绍了在全局程序集缓存(GAC)中注册应用程序DLL的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Windows Embedded Compact 7作为我的操作系统。我正在使用.NET CF 3.5进行开发

I am using Windows Embedded Compact 7 as my O/S. I am developing using the .NET CF 3.5

我开发了两个Managed Dll和几个Managed Executable。

I have developed two Managed Dlls and several Managed Executables.

可执行文件引用了两个管理Dlls。我希望在部署O / S时在GAC中注册两个Managed dll,以便所有托管可执行文件都可以使用托管dll。

The executables have references to the two managed Dlls. I want the two Managed dlls to be registered in the GAC when the O/S is deployed so that all managed executables can use the managed dlls.

我的O / S设计设置为将托管Dll与两个相应的.GAC文件一起部署到Windows文件夹中,每个Dll一个。这些引用了\ Windows \< managed dll file>在它们中。

I have my O/S design setup to deploy the managed Dlls into the Windows Folder along with two corresponding .GAC files, one for each Dll. These have a reference to \Windows\<managed dll file> in them.

然后我在CE Startup上运行我的第一个应用程序(通过使用HKEY_LOCAL_MACHINE \Init注册表设置)。这从不同的目录运行到Windows目录。

I then have my first application running on CE Startup (by using the HKEY_LOCAL_MACHINE\Init registry setting). This runs from a different directory to the Windows directory.

我所遇到的是,在大多数情况下,当启动O / S时,启动时运行的托管应用程序无法找到这两个管理dll。如果我查看Windows目录,我可以看到两个Dll尚未添加到GAC和
这就是为什么我的应用程序无法看到它们。

What I am experiencing is that on most occasions when the O/S is booted the Managed Application that runs on startup fails to find the two managed dlls. If I look in the Windows directory I can see that the two Dlls have not been added to the GAC and this is why my application cannot see them.

在一些尽管如此,它已经成功运行,我的应用程序已成功运行,但在设备重置期间这种情况永远不会一致。

On a few occasions though, it has worked and my application has run successfully but this is never consistent across resets of the device.

我不知道为什么它有几次工作但是主要 不起作用。我错过了什么吗?注册?文件?

I am at a loss as to why it has worked on a few occasions but mainly doesn't work. Am I missing something? Registry? Files?

谢谢

推荐答案

我不是CLR专家,但我不是认为只删除文件在添加到GAC方面做了任何事情。您是否必须在设备上使用GACUTIL来添加它们?

I'm not a CLR expert but I don't think that just dropping files anywhere does anything with respect to adding to the GAC. Don't you have to use GACUTIL on the device to add them?

Paul T。


这篇关于在全局程序集缓存(GAC)中注册应用程序DLL的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆