Remove Attach Listener

Supporting 4.1 and up
Post Reply
brunoramos96
Phidgetsian
Posts: 10
Joined: Wed Sep 26, 2018 2:14 pm
Contact:

Remove Attach Listener

Post by brunoramos96 »

Can anyone explain me the purpose of removeAttachListener in Phidgets22 library?
I'm with some problems. When I start my app, I do my configurations and then I arrive at the activity where I do the measurement of acceleration with the 1041 accelometre. But when I go back to do new configurations and return to the activity of measurement, I can no longer get data of the accelometre.
The activity, according to the lifecycle of an activity, is destroyed when I return to the activity before, so I was expecting that the part of the code that specifies the attachListener and detachListener would work normaly. Since it doesn't happen I'm wondering if the void removeAttachListener would help, but I don't know how to declare it or even what is its purpose.

Hope someone can help me!
User avatar
mparadis
Site Admin
Posts: 660
Joined: Fri Oct 28, 2011 12:17 pm
Contact:

Re: Remove Attach Listener

Post by mparadis »

Do you think you could post some of your code here? It's hard to understand what might be going wrong without seeing the code.
brunoramos96
Phidgetsian
Posts: 10
Joined: Wed Sep 26, 2018 2:14 pm
Contact:

Re: Remove Attach Listener

Post by brunoramos96 »

mparadis wrote:Do you think you could post some of your code here? It's hard to understand what might be going wrong without seeing the code.
After some tries I fugured out a way. Thanks anyway :wink:
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests