-3
        // 
        // textEdit1
        // 
        this.textEdit1.Location = new System.Drawing.Point(4, 20);
        this.textEdit1.Name = "textEdit1";
        this.textEdit1.Properties.BorderStyle = DevExpress.XtraEditors.Controls.BorderStyles.HotFlat;
        this.textEdit1.Properties.MaxLength = 15;
        this.textEdit1.Properties.NullValuePrompt = "<Beta Code>";
        this.textEdit1.Properties.NullValuePromptShowForEmptyValue = true;
        this.textEdit1.Properties.PasswordChar = '*';
        this.textEdit1.Size = new System.Drawing.Size(250, 22);
        this.textEdit1.TabIndex = 2;

I get 5 warning messages and a call stack error because of this, meaning I can't view it in designer mode.

Warning Messages:

Warning 1   Object reference not set to an instance of an object.
Warning 2   Object reference not set to an instance of an object.
Warning 3   Object reference not set to an instance of an object.
Warning 4   Object reference not set to an instance of an object.
Warning 5   Object reference not set to an instance of an object.

Any help would he appreciated. Thanks in advance.

Call Stack:

at DevExpress.XtraEditors.Repository.RepositoryItem.CreateDesigner()
at DevExpress.XtraEditors.Repository.RepositoryItem.FilterProperties(PropertyDescriptorCollection collection)
at DevExpress.XtraEditors.Repository.RepositoryItem.System.ComponentModel.ICustomTypeDescriptor.GetProperties(Attribute[] attributes)
at System.ComponentModel.TypeDescriptor.MergedTypeDescriptor.System.ComponentModel.ICustomTypeDescriptor.GetProperties(Attribute[] attributes)
at System.ComponentModel.TypeDescriptor.GetPropertiesImpl(Object component, Attribute[] attributes, Boolean noCustomTypeDesc, Boolean noAttributes)
at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.GetPropertiesHelper(IDesignerSerializationManager manager, Object instance, Attribute[] attributes)
at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializePropertyAssignStatement(IDesignerSerializationManager manager, CodeAssignStatement statement, CodePropertyReferenceExpression propertyReferenceEx, Boolean reportError)
at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeAssignStatement(IDesignerSerializationManager manager, CodeAssignStatement statement)
at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeStatement(IDesignerSerializationManager manager, CodeStatement statement)
Keith
  • 18,957
  • 10
  • 75
  • 119
Neel
  • 23
  • 1
  • 6

2 Answers2

0

You simply have forgotten to feed one of your objects with data. Ensure that all sources and objects that require data do get it.

Begin by omitting some of your code with try and catch to see where the error got its origin if you can do that by checking the Call Stack.

Eric Herlitz
  • 22,490
  • 25
  • 106
  • 149
0

I suspect the TextEdit.Properties object isn't being instantiated based on the # of warnings being generated (5 warnings for 5 references to the Properties property). A quick Google search shows a few other people have had this problem with DevExpress controls though I can't find any resolution.

Here are a few things you should try:

  1. Make sure you have referenced all of the applicable DevExpress DLLs.
  2. Try removing your TextEdit control from the form/control/etc and add it again.
  3. Submit your issue to the DevExpress support center. They are usually very responsive.
Keith
  • 18,957
  • 10
  • 75
  • 119