コード例 #1
0
 public ucDeviceProperty(HartDevice dev)
 {
     InitializeComponent();
     hartDevice = dev;
     propertyGrid1.SelectedObject = hartDevice;
     devType = ProjectType.Hart;
 }
コード例 #2
0
 public void UpdateDevice(HartDevice dev)
 {
     hartDevice = dev;
     devType    = ProjectType.Hart;
     propertyGrid1.SelectedObject = hartDevice;
     propertyGrid1.Refresh();
 }
コード例 #3
0
        public ucDeviceProperty(object dev)
        {
            InitializeComponent();

            if (dev.GetType() == typeof(HartDevice))
            {
                hartDevice = (HartDevice)dev;
                propertyGrid1.SelectedObject = hartDevice;
                devType = ProjectType.Hart;
            }
            else if (dev.GetType() == typeof(DPDevice))
            {
                dpDevice = (DPDevice)dev;
                propertyGrid1.SelectedObject = dpDevice;
                devType = ProjectType.DP;
            }
        }
コード例 #4
0
 public void Add(HartDevice dev)
 {
     hartDevices.Add(dev);
 }