I'm experiencing a rather strange bug. I have two Sub-Application windows in my program, both which load at startup and one is modal. The one which is modal is the login window, which you need to successfully get past to access the program. This grabs frame 2 for the login screen and works no problem.

However this is where the problem starts. My second sub-application is embedded (which is to say it doesnt pop up, have a border etc) and changes its frame to reflect whatever button is selected. What I WANT to happen is if you click "Button 3" it jumps to frame 3, "Button 4" to frame 4 etc.

But it doesnt; It jumps one frame ahead every time. I click "Button 3" and it opens Frame 4. I click Button 4 and it opens Frame 5. I click button 5 and it tried to open Frame 6... but it doesn't exist yet. The first sub-application window doesnt do this as I tell it to look at Frame 2 - which it does.

I only have these two Button events on the malfunctioning sub-app and nothing else can control it or give it an order. I've tried removing the sub-app completely and placing a new one in but that doesn't work either.

Can anyone shed any light as to what's going on here? Thanks