MDi Modal From  
Author Message
LuckyL





PostPosted: Visual C# General, MDi Modal From Top

Hi

To make a form modal we use showdialog. But when you do this with mdi forms it gives an error. So how do you show a mdi form as a modal form

Thanks in advance.




Visual C#3  
 
 
Gabriel Lozano-Moran





PostPosted: Visual C# General, MDi Modal From Top

You can't. A MDI child has the window style WS_CHILD and what you want is change it with the WS_POPUP style. Imho it should be possible to switch the window style with a SendMessage or maybe even by overriding the WndProc, but I have never tried it out myself: