# Open/CloseView methods don't run when using RobotPositionCallback2

**URL:** <https://forum.universal-robots.com/t/open-closeview-methods-dont-run-when-using-robotpositioncallback2/26248>\
**Category:** Report a Bug\
**Created:** [January 17, 2023, 7:16pm UTC](https://forum.universal-robots.com/t/open-closeview-methods-dont-run-when-using-robotpositioncallback2/26248 "2023-01-17T19:16:54Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![eric.feldmann](https://avatars.discourse-cdn.com/v4/letter/e/94ad74/32.png) [@eric.feldmann](https://forum.universal-robots.com/u/eric.feldmann)\
**Post date:** [January 17, 2023, 7:16pm UTC](https://forum.universal-robots.com/t/open-closeview-methods-dont-run-when-using-robotpositioncallback2/26248/1 "2023-01-17T19:16:54Z")

</div>

Steps to reproduce:  
Create a button that invokes the following method: `apiProvider.getUserInterfaceAPI().getUserInteraction() .getUserDefinedRobotPosition(new RobotPositionCallback2()`

Expected Behavior:  
Polyscope switches from the program screen to the Move Tab, allowing the positioning of the robot, and then clicking OK to save the point, or Cancel to go back. I would expect that changing screens this way would trigger the closeView() method, and upon returning to the program screen on onOK or onCancel, openView would be called

Actual Behavior:  
Neither closeView nor openView are run when the screen changes in this manner.

Affected Version(s):  
Polyscope 5.13, API 5.11
