private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { Cursor = Cursors.WaitCursor; int iError = -1; textBoxSerialNo.Text = DeviceInfoClass.GetDeviceSN(1, ref iError, 2, UtilityClass.GetIPAddress(), UtilityClass.GetIPort()); if (iError > -1) { MessageBox.Show(@"Error Connecting to device.", @"Device Connection Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } Cursor = Cursors.Default; }
private void buttonOk_Click(object sender, EventArgs e) { DeviceInfoClass.DDevice().Disconnect(); Close(); }