示例#1
0
文件: devinfo.cs 项目: leuher/WeDo
        private void BtTurnOff_Click(Object Sender, EventArgs e)
        {
            Int32 Res = FHub.TurnOff();

            if (Res != wclErrors.WCL_E_SUCCESS)
            {
                MessageBox.Show("Turn Off failed: 0x" + Res.ToString("X8"));
            }
        }
示例#2
0
文件: main.cs 项目: leuher/WeDo
        private void btDisconnect_Click(object sender, EventArgs e)
        {
            wclWeDoHub Hub = GetSelectedHub();

            if (Hub != null)
            {
                Int32 Res = Hub.TurnOff();
                if (Res != wclErrors.WCL_E_SUCCESS)
                {
                    MessageBox.Show("Disconnect failed: 0x" + Res.ToString("X8"));
                }
            }
        }