0

我编写了一个基于 .NET Framework 3.5 SP1 的 Windows 窗体应用程序,它在 windows server 2003 版上运行。我试图添加另一个用户来使用这个程序并得到以下错误

The Zone of the assembly that failed was: MyComputer



2012-04-11 13:30:43,326 [1] ERROR UclUserLogin - [btnSubmit_Click] The type initializer for 'Oracle.DataAccess.Client.OracleConnection' threw an exception. 
System.TypeInitializationException: 
The type initializer for 'Oracle.DataAccess.Client.OracleConnection' threw an exception. --->               
System.TypeInitializationException: The type initializer for 'Oracle.DataAccess.Client.RegAndConfigRdr' threw an exception. --->   
System.Security.SecurityException: Requested registry access is not allowed.
at System.ThrowHelper.ThrowSecurityException(ExceptionResource resource)
at Microsoft.Win32.RegistryKey.OpenSubKey(String name, Boolean writable)
at Microsoft.Win32.RegistryKey.OpenSubKey(String name)
at Oracle.DataAccess.Client.RegAndConfigRdr..cctor()
The Zone of the assembly that failed was:
MyComputer
--- End of inner exception stack trace ---
at Oracle.DataAccess.Client.RegAndConfigRdr.ReadEntriesForRegistryAndConfig()
at Oracle.DataAccess.Client.OracleInit.Initialize()
at Oracle.DataAccess.Client.OracleConnection..cctor()
--- End of inner exception stack trace ---
at Oracle.DataAccess.Client.OracleConnection..ctor(String connectionString)
4

1 回答 1

0

由于用户没有完全控制权限,Oracle 客户端无法访问某些注册密钥。

您需要使用 regedit,导航到注册表项并右键单击具有上述名称的文件夹。然后选择权限,您可以更改每个用户的权限。

一个可能的关键是

`HKLM/Software/Policies/Microsoft/Windows/Installer`

如果您找不到正确的密钥,您可以使用进程监视器来检查它到底是什么。

进程监视器可以下载微软

于 2012-11-28T05:59:58.500 回答