Please help me with back button navigation

In my application i have a few roImageCanvas screens. I want to navigate from one screen to other using back button. So i have used remote back button (index 0) and statement ‘return -1’ inside it in my code. I am able to navigate back but its getting stuck. What can be done to fix this ?

Please suggest me.
Thanks in advance