Jump to content

More than one window


Rodger
 Share

Recommended Posts

Hello,

I have made a main Window with a menu-item. Every time I click on the menu-item it opens a new window which should be the case. But .... when I close one of windows which was opened by the menu-item, it closes everything in stead of only that specific one.

How can I solve this, it would be nice if you can give me an example.

Thxs,

Rodger

Edited by Rodger
Link to comment
Share on other sites

You have something like

If $msg = $GUI_EVENT_CLOSE Then ExitLoop

or

If $msg = $GUI_EVENT_CLOSE Then Exit

in you script. Both GUIs sent the $GUI_EVENT_CLOSE while closing, so you have to enhance that part to something like

If $msg = $GUI_EVENT_CLOSE Then

if WinActive($GUI_Main) then

exit

else

guidelete($GUI_Menu)

endif

endif

Hard to say the syntax needed without a sample :)

Link to comment
Share on other sites

I was a little bit to quick.

The moment I closed one of the extra opened window, I can't close the other extra opened window(s) any more because the Gui has been deleted. Next to that, it closes always the first extra opened window and not the window you want to close.

Edited by Rodger
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...