示例#1
0
        private void button2_Click(object sender, EventArgs e)
        {
            var controller = new DeviceController();
            Device testDev = controller.GetAllDevices().Last();

            AddRule ar = new AddRule(testDev);
            ar.ShowDialog();
        }
示例#2
0
        private void bModify_Click(object sender, EventArgs e)
        {
            //Print output statement as to the event.
            DebugOutput.Print("Dashboard: Modify Device");

            //Populate appropriate objects/fields.
            modify_lbDeviceList.Items.Clear();
            var controller = new DeviceController();
            foreach (var dev in controller.GetAllDevices())
            {
                modify_lbDeviceList.Items.Add(dev);
            }

            //Bring page to user's view.
            pTabPanel.SelectedTab = pModifyDevice;
        }
示例#3
0
        private void bStopProcess_Click(object sender, EventArgs e)
        {
            //Print output statement as to the event.
            DebugOutput.Print("Dashboard: Stop Device Process");

            //Populate appropriate objects/fields.
            stop_lbDevice.Items.Clear();
            var controller = new DeviceController();
            foreach (var dev in controller.GetAllDevices())
            {
                stop_lbDevice.Items.Add(dev);
            }

            //Bring page to user's view.
            pTabPanel.SelectedTab = pStop;
        }
示例#4
0
        private void button7_Click(object sender, EventArgs e)
        {
            var controller = new DeviceController();
            Device testDev = controller.GetAllDevices().Last();

            AddCommunicator ai = new AddCommunicator(testDev,true);
            ai.ShowDialog();
        }