Help Closing Custom Menu

Hi. I haven't touched RPGmaker in a long time (using VX Ace) and I'm new to these forums, hopefully this is the right place to post this. I decided I would see if I could figure out scripting well enough to create a custom level up system. I'm sure I'm not doing everything 'right', but I'm actually figuring out and accomplishing a lot (not a complete newbie, have a bit of a programming background).

So far I've added some more variables to the game_actor script to keep track of points invested in certain things when leveling up. I've created a custom window and got the graphics showing up how I want them. I've even created a scene for the level up window, and figured out handlers to detect key input, at least well enough so that the player can navigate the menu.

My problem is, once I've called the scene (which I'm currently doing through a script event on the map for easy testing) and that scene has created the level up window, I'm not sure how to get out of it. The handler detects the cancel button being pressed, but I'm not exactly sure what do to when it's pressed. I've tried several things, but none seem to work. Currently pressing the cancel button causes the window to freeze, (unless I add code to activate the window when cancel is pressed, but that's the opposite of what I want.). I would like pressing cancel to close the window and return to the map. I'm probably missing something really simple, it seems like some of the other stuff I've done should be more complicated, but this is giving me some trouble.
Moved to: RGSSx Script Support

Have you checked what the other scenes do to handle this? You should just need to do the same. You might need to post your script here so we can see what you've done.
I knew I was missing something simple! I had seen the SceneManager being used in other Classes, which is how I figured out how to call my scene, but for some reason I didn't see it in my list of scripts. Now that I've found the SceneManager script, I've realized I was looking for the return method. Works like a charm!

Sorry for wasting anyone's time, hopefully the post helps someone else struggling with it in the future.

Original thread: https://forums.rpgmakerweb.com/threads/help-closing-custom-menu.134932/