/// <summary> /// The device needs to pair with the POS to confirm proper security and configuration. /// If a previously established authToken was sent to the device, this step will be skipped. /// (Until the token expires and a new pairing exchange occurrs.) /// Not all connection types require paring. For example, a USB direct connection does not send pairing messages. /// </summary> void OnPairingCode(string code) { PairingCode?.Invoke(code); // Some fallback code if PairingCode event isn't being handled - not necessary but makes the sample more robust if (PairingCode == null) { System.Windows.Forms.MessageBox.Show($"Enter this pairing code on the Clover Device to confirm the computer and device have identified each other correctly.\n\n\t Pairing Code: {code}", "Clover Device Network Pairing", System.Windows.Forms.MessageBoxButtons.OK, System.Windows.Forms.MessageBoxIcon.Information); } }