using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Collections; using System.ComponentModel; using System.ComponentModel.Design; using System.Windows.Forms.Design; // 自定义编辑器,用于 DataMonitor 属性 public class PlcDataMonitorEditor : CollectionEditor { public PlcDataMonitorEditor(Type type) : base(type) { } // 禁用添加新项 //protected override object CreateInstance(Type itemType) //{ // // 返回 null 表示不允许创建新实例 // //return null; //} //protected override bool CanRemoveInstance(object value) //{ // return true; // 返回 false 表示不允许删除 //} }