private void RegisterConnection() { _connectionCallback = new ReaPi.connectionCallbackPtr(OnConnectionCallback); ReaPi.EErrorCode tmpError = ReaPi.RegisterConnectionCallback(_connectionCallback, new IntPtr(0)); if (tmpError == ReaPi.EErrorCode.OK) { SendToDashboard(MessageType.LOG, "RegisterConnectionCallback() - Status.OK", "", ""); } else { SendToDashboard(MessageType.LOG, "RegisterConnectionCallback() - Status.Error", tmpError.ToString(), ""); } }