Math

Answered

Error, -[IINKEditor setPart:error:]::109 INVALID_OPERATION:

copied the same code from demo to my project , then replace the certificate and config(resource), got the error 


Best Answer

Dear War E,


currently, we recommend you use the pod, it will be easier.


The API in between iOS and Android are similar, which is why I point to Android ; the iOS APIs are available in your xcode project.


If you want to manually add the libraries, they shall be linked in the following order:

libMyScript2D.a
libMyScriptAnalyzer.a
libMyScriptDocument.a
libMyScriptGesture.a
libMyScriptInk.a
libMyScriptMath.a
libMyScriptPrediction.a
libMyScriptShape.a
libMyScriptText.a
libMyScriptEngine.a
libiink.a


Best regards,


Olivier


Dear Yehua Hao,


Thank you for contacting us.


Currently, the error message by itself, without a project or your code  doesn't help much.


I would tend to say that either your editor is closed, your fontMetricsProvider has not been set or your part is already attached. You can refer to the API documentation:
https://developer.myscript.com/refguides/interactive-ink/android/1.4/com/myscript/iink/Editor.html#setPart-com.myscript.iink.ContentPart-


Best regards,


Olivier

Thanks for your reply,  I found the note  ‘IINKErrorRuntime when this editor cannot be configured’ and so on, but how can I verify the editor is valid, and the Diagram、Drawing、Text、Text Document both work fine,  except for math

In a word, how can I know the editor is closed,  whether had I set FontMetricsProvider, whether the part is already bound, or whether the editor is configured

Dear Yehua Gao,


currently, I am not sur to understand your question.


Indeed, if proceeding as in our code samples, if editor is closed you can use the corresponding API function: https://developer.myscript.com/refguides/interactive-ink/android/1.4/com/myscript/iink/Editor.html#isClosed--


In the same way, if the fontMetrics provider could not be set, an exception will be raised: https://developer.myscript.com/refguides/interactive-ink/android/1.4/com/myscript/iink/Editor.html#setFontMetricsProvider-com.myscript.iink.text.IFontMetricsProvider- ...


So, all this looks like a coding issue. Simply compare your project with our code samples, and you shall be able to find the cause of the error checking the exceptions. Otherwise, feel free to provide us with your full project (that we can run out of the box) ; this way, we shall be able to understand what is not correct.


Best regards,


Olivier

This is the API document for Android, I can't find closed all of the demo app after the pods are installed! Can you send me the API document for iOS, thanks!

I manually imported the MyScript library instead of using CocoaPods. I checked you demo binary with otool , and linked libc++.1.tbd, libobjec.A.tbd, libSystem.B.tbd, but it does't work!  In addition, myapp@myscript.com is not valid, I failed to send the email

Indeed, on iOS, the order of the libraries shall be carefully followed, otherwise the engine will not be created.  

This is the answer I found about 「NO_SUCH_ENGINE」,and what is the order of the libs

Answer

Dear War E,


currently, we recommend you use the pod, it will be easier.


The API in between iOS and Android are similar, which is why I point to Android ; the iOS APIs are available in your xcode project.


If you want to manually add the libraries, they shall be linked in the following order:

libMyScript2D.a
libMyScriptAnalyzer.a
libMyScriptDocument.a
libMyScriptGesture.a
libMyScriptInk.a
libMyScriptMath.a
libMyScriptPrediction.a
libMyScriptShape.a
libMyScriptText.a
libMyScriptEngine.a
libiink.a


Best regards,


Olivier