تمكين تصميم الدعم الوقت لتحكم العضو في Visual Studio 2008

StackOverflow https://stackoverflow.com/questions/525498

سؤال

ولقد خلق usercontrol GridEx: UserControl. على أن تحكم I مبيكى GridControl (DevExpress تحكم DataGrid). لقد خلق الملكية DataGrid الذي يعود التحكم DataGrid الداخلية (المضافة سابقا) كيفية تمكين الدعم لتصميم DataGrid؟ أنا أحاول أن أضع

[Designer("DevExpress.XtraGrid.Design.GridControlDesigner,
    DevExpress.XtraGrid.v8.2.Design", typeof(IDesigner))] 

ولكن يمكنني الحصول على هذا الخطأ: فشل إنشاء المكون 'DataGridControl.
رسالة الخطأ التالي:

System.NullReferenceException: Object reference not set to an instance of an object.
  at DevExpress.XtraGrid.Design.GridControlDesigner.Initialize(IComponent component)
  at System.ComponentModel.Design.DesignerHost.AddToContainerPostProcess(IComponent component, String name, IContainer containerToAddTo)
  at System.ComponentModel.Design.DesignerHost.Add(IComponent component, String name)
  at System.ComponentModel.Design.DesignerHost.System.ComponentModel.Design. IDesignerHost.CreateComponent(Type componentType, String name)
   at System.ComponentModel.Design.DesignerHost.System.ComponentModel. Design.IDesignerHost.CreateComponent(Type componentType)
   at System.Drawing.Design.ToolboxItem.CreateComponentsCore(IDesignerHost host)
   at System.Drawing.Design.ToolboxItem.CreateComponentsCore(IDesignerHost host, IDictionary defaultValues)
   at System.Drawing.Design.ToolboxItem.CreateComponents(IDesignerHost host, IDictionary defaultValues)
   at System.Windows.Forms.Design.OleDragDropHandler.Cre...
هل كانت مفيدة؟

المحلول 2

والحل يمكن أن تقوم هنا:

http://www.devexpress.com/kb=A577

نصائح أخرى

وحاول استخلاص تحكم المستخدم من تحكم شبكة DevExpress بدلا من فئة "UserControl".

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top