In PB 2017 R2, can a Main! window be modal, ie, focus can not go to another window or menu when open.
In PB 2017 R2, can a Main! window be modal, ie, focus can not go to another window or menu when open.
Greetings, Pete -
I'm not saying this is an ideal solution or easy to implement...but can you (1) enforce restrictions on the "modal" window so that it opens only when no other windows are already open, and (2) disable all menu items and other means of opening other windows when the "modal" window is open?
Regards, John
Hi Pete;
No, Main windows can never be modal. However, you can easily "fake it out" by placing code in the Windows "deactivate" event that then immediately returns focus back to the main window. Thus to the App user, the Main window "seems" modal. ;-)
HTH
Regards ... Chris
Ultimate Suite allows you to open windows as Modal windows.
https://www.pbultimatesuite.com/EN/modernize-pb-interface/powermodal.html
Also, in reference to another post, I was calling GetActiveSheet in the deactivate event. It was throwing a null reference error. Why would that be? I was calling it for the MDI window, w_frame.