Jump to content

disable minimize, maximize, close


kgreer
 Share

Recommended Posts

I'm trying to disable the entire form while a function is running. I can disable each control using guictrlsetstate(), but I also want to disable the minimize, maximize, and close buttion while the function is running. I tried using guictrlsetstate() on the form as well, but that did not work. Any thoughts?

Link to comment
Share on other sites

Search for EnableMenuItem in forum

Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs, and the Universe
trying to produce bigger and better idiots.
So far, the Universe is winning.

Link to comment
Share on other sites

GuiSetState(@SW_Disable,$winhandle)

msgbox(262160,"","An error message")

;controls are reset

GuiSetState(@SW_Enable,$winhandle)

This works, but the form window will minimize itself after the msgbox is closed. I'm not sure what is causing that. I can counteract that by adding winsetontop(), but I don’t want to force the window to always be on top.

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...