Reflection not working for DevExpress.XtraGrid dll

412 Views Asked by At

I am using Reflection to get all the Types of DevExpress.XtraGrid assembly, but its throwing me the ReflectionTypeLoadException within a windows app. My Code:

var DLL = Assembly.LoadFile(@"D:\References\DevExpress.XtraGrid.v7.3.dll");
var theType1 = DLL1.GetTypes();//exception here

Actually I want to get all properties of Type DevExpress.XtraGrid.Columns.GridColumn class within the dll.just tried to get all Types as its not getting for the Type mentioned.I want this:

var DLL1 = Assembly.LoadFile(@"D:\References\DevExpress.XtraGrid.v7.3.dll");
var theType1 = DLL1.GetType("DevExpress.XtraGrid.Columns.GridColumn");//theType1 is giving null

I have tested the same for System.Windows.Forms.Label Type in System.Windows.Forms dll. It worked perfectly, donno why not for DevExpress controls.

~Deepthi

1

There are 1 best solutions below

5
On

yes you will get error because DevExpress.XtraGrid is depend on another dll.i think you have to load all dll that is required to DevExpress.XtraGrid dll