How to create a child window without min/max,title & attach to mainframe window?

Hi,
Could somebody tell me ,how to
attach the child window frame to the main window frame, i.e once the new window is created it should NOT have any min/max buttons and title border, should like they part of mainframe window.
if main window is maximized,the child window should also draged.
(in MDI application)
Regards,
Mohan

mohan
[368 byte] By [mohanrajh] at [2007-11-17 11:49:49]
# 1 Re: How to create a child window without min/max,title & attach to mainframe window?
Hi,

You can set the styles in the PreCreateWindow function in your Childframe class. Take a look at the sample code.BOOL CChildFrame::PreCreateWindow(CREATESTRUCT& cs)
{
cs.style = ~WS_CAPTION;
cs.style = WS_CHILD;
cs.style &= ~FWS_ADDTOTITLE;

if( !CMDIChildWnd::PreCreateWindow(cs) )
return FALSE;

return TRUE;
}

All Luck.

http://www.geocities.com/contactgirish/homepage.html>> VC++ Links,Code,Tutorials,Downloads & Notes.

If you have some time, you can sign the guestbook there. Thank you.
VGirish at 2007-11-10 8:06:51 >
# 2 Re: How to create a child window without min/max,title & attach to mainframe window?
Hi Girish,
Well, thanx for your hint, but the child window is not maximized. I tried this code
cs.style = WS_MAXIMIZE;
But it didnt have any effect.
Do you have any idea...
Regards,
Mohan

mohan
mohanrajh at 2007-11-10 8:07:53 >