@AnneRanch said in How to rewrite MDI example structure C++ code:
I now have two processes running and the "myProcess" dialog works fine - what I wnat is to insert the dialog from one process to another .
You have asked this previously, and the answer remains the same. So long as you have "separate processes" --- something run via QProcess --- you cannot "insert the dialog from one process to another ." MDI or not makes no difference. If you wish to have a dialog from one set of code appear in another set of code, they must both be in the same application, no independent processes.
On a separate matter, if you do wish to use QProcess you still presently have:
myProcess->start();
int result_execute = myProcess->execute(program); //, arguments);
We have said before that this will run two instances of the btscanner program, and so you should find there are two btscanner windows opened, which is not right.