BlinkIDDemo.MainPage.mRecognizer_OnInitializationError C# (CSharp) Method

mRecognizer_OnInitializationError() public method

Handles initialization error(invalid license)
public mRecognizer_OnInitializationError ( InitializationErrorType errorType ) : void
errorType InitializationErrorType initialization error type(only INVALID_LICENSE_KEY at the moment)
return void
        void mRecognizer_OnInitializationError(InitializationErrorType errorType)
        {
            // handle licensing error by displaying error message and terminating the application
            if (errorType == InitializationErrorType.INVALID_LICENSE_KEY) {
                MessageBox.Show("Could not unlock API! Invalid license key!\nThe application will now terminate!");
                Application.Current.Terminate();
            } else {
                // there are no other error types
                throw new NotImplementedException();
            }
        }