So I have a menu form for my application, let us call it the grandparent. The user clicks a button, and it calls another form, let’s call it the parent form, with form.show(). Because I used show(), and not showdialog(), I can play around with either form now.
Then, in the parent form, I call a third form, let’s call it child, with a form.showdialog(). I want the user to have to close the child form before being able to do anything with the parent form, and that is exactly what happens. The problem is that now I can’t use the grandparent form either, it is locked until I close the child form, and I don’t want it to be.
In other words, I want the child form to be modal, but only in respect the parent form, not the grandparent form. Can such a thing be done?
if you can live with the fact that your parent and child forms live on another thread than you grandparent (so you will have to invoke when you need to use controls on the other thread) you could start a 2nd UI thread for your parent form …
when the modal dialog blocks the message queue of the parent forms UI thread, the grandparents UI thread will still have its own non-blocked message queue …
so instead of calling
somewhere in the code of your grandparent-form call