//
// 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;
因爲這樣我得到5條警告消息和一個調用堆棧錯誤,這意味着我無法在設計器模式下查看它。調用堆棧錯誤 - C#
警告消息:
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.
任何幫助,他讚賞。提前致謝。
調用堆棧:
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)
的可能重複[什麼是.NET一個NullReferenceException?](http://stackoverflow.com/questions/4660142/what-is-a-nullreferenceexception-in-net) –
this.textEdit1存在嗎?調用堆棧錯誤是什麼? – rlemon
@rlemon我會將它添加到主帖子 – Neel