The normal way to keep an OK button enabled is to simply feed it with an Until Break object. So one way to stop it is to insert a Break if whatever condition arises.
Another slightly more sophisticated way is to enter a name in Declared Name ( see LH panel in the screenshot ) and then use that to disable it. In this case I've called it Btn_OK and in the formula box the Btn_OK.EnableOnPing = FALSE disables the button.
Although the property is EnableOnPing, note that setting this to FALSE disables the button instantly even if it is called from another loop in your program.
The normal way to keep an OK button enabled is to simply feed it with an Until Break object. So one way to stop it is to insert a Break if whatever condition arises.
Another slightly more sophisticated way is to enter a name in Declared Name ( see LH panel in the screenshot ) and then use that to disable it. In this case I've called it Btn_OK and in the formula box the Btn_OK.EnableOnPing = FALSE disables the button.
Although the property is EnableOnPing, note that setting this to FALSE disables the button instantly even if it is called from another loop in your program.