tags:

views:

459

answers:

1

This is the detailed error info.

Failures: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException: Unknown error (0x80005000) at System.DirectoryServices.DirectoryEntry.Bind(Boolean throwIfFail) at System.DirectoryServices.DirectoryEntry.Bind() at System.DirectoryServices.DirectoryEntry.get_NativeObject()

Code that causes the above exception:

 DirectoryEntry de1 = new DirectoryEntry("RNA:");
 IRnaNamespace rnaNamespace = (IRnaNamespace)de1.NativeObject;

After the del object is created, I try to watch the values for variant del, and this is the result: link text alt text

The OS is Windows2008 R2 64bits. And it can run successfully on Windows2008Sp2 32bit.

A: 

The error is caused by the following statement:

DirectoryEntry de1 = new DirectoryEntry("RNA:");

Because it will call another project AAA which is built in 32 bits system to create the directory. After rebuilt AAA in 64 bits, everything is OK.

Carlos_Liu