public class ObjList<T> : CollectionBase, ICustomTypeDescriptor { }
在你的类 集合 属性上加一个标签: [EditorAttribute(typeof(CustomUITypeEditor), typeof(System.Drawing.Design.UITypeEditor))] public List<T> T { get; set; } 新建一个类 CustomUITypeEditor: public class CustomUITypeEditor: System.Drawing.Design.UITypeEditor 重写 public override System.Drawing.Design.UITypeEditorEditStyle GetEditStyle(ITypeDescriptorContext context){ return System.Drawing.Design.UITypeEditorEditStyle.None; }
110,566
社区成员
642,567
社区内容
加载中
让您成为最强悍的C#开发者
试试用AI创作助手写篇文章吧