Android Question raiseEvent2 causing ArrayIndexOutOfBoundsException

Discussion in 'Android Questions' started by Ddddimmma, Sep 20, 2015.

  1. Ddddimmma

    Ddddimmma Member Licensed User

    I am trying to post an event from a native library (java) back to b4a.
    I also need the event to be received while the activity is paused, so i tried raiseEvent2.
    My usage:
    ba.raiseEvent2(sender, true, eventName, false, eventParams);
    Doing so, i am getting the following error:
    ~e:java.lang.ArrayIndexOutOfBoundsException: length=12; index=-1

    Could you please assist?
    BTW, using raiseEventFromDifferentThread works but it dispatches the event to a message queue and the event would run upon activity resume - not a good solution for us because we need to notify the client activity that the event occurred event if it is paused.
  2. Erel

    Erel Administrator Staff Member Licensed User

  3. Ddddimmma

    Ddddimmma Member Licensed User

    Done, thanks
  4. Ddddimmma

    Ddddimmma Member Licensed User

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice