Your sub vi appearance is set to dialog which will make your sub vi run at the top level so you will not be able to access your main vi. Try to set the vi appearanvce to floating and check it. Actually you haven't used any sub -panel thats why it pops-up outside.
-----
I don't believe in Hard work. I love my work