How to remove rezise capability 
Author Message
 How to remove rezise capability

Hi i have a problem with removing the resize capability from the main
window. Can anyone tell me how this is done?

thanx
/Anders



Mon, 24 Sep 2001 03:00:00 GMT  
 How to remove rezise capability

Quote:

>Hi i have a problem with removing the resize capability from the main
>window. Can anyone tell me how this is done?

Where are you having a problem? What have you tried so far?

Here are some things I would try:
1) Change the window style of the main window to remove the
   WS_THICKFRAME style.
2) Handle WM_SIZING, and adjust the rectangle to prevent a
   change in size.
3) Remove the SC_SIZE item from the system menu

 - Katy

--
Katy Mulvey             Please post replies to the newsgroup, thanks!
ORMEC Systems           MVP/VC++
http://www.ormec.com    http://support.microsoft.com/support/supportnet/
                           supportpartners/mvps/brochuregeneral.asp  



Mon, 24 Sep 2001 03:00:00 GMT  
 How to remove rezise capability

Quote:
>Hi i have a problem with removing the resize capability from the main
>window. Can anyone tell me how this is done?

Anders,

Make the window non-resizable by ensuring it doesn't have the
WS_THICKFRAME style. Have a look at Knowledge Base article Q133256
"How to Prevent Mainframe Window from Being ReSized" for an example.

Dave
----
Address is altered to discourage junk mail.
Please post responses to the newsgroup thread,
there's no need for follow up email copies.
http://www.bj.co.uk



Mon, 24 Sep 2001 03:00:00 GMT  
 How to remove rezise capability
What are you trying ? To set the window border style ?
Maybe you can try to catch the WM_SIZING event.

Gabriel.

Quote:

> Hi i have a problem with removing the resize capability from the main
> window. Can anyone tell me how this is done?

> thanx
> /Anders



Sun, 21 Oct 2001 03:00:00 GMT  
 How to remove rezise capability
Capturing WM_SIZING *may* work, but the best way to achieve this is to
respond to WM_GETMINMAXINFO (OnGetMinMaxInfo in MFC)

This will give you the option of specifying a minimum and maximum size for
the window (via the MINMAXINFO structure). By setting min=max you end up
with a fixed window. In that situation, however, beware of the possibility
of iconising or maximising.

--
Mark Webb (ADT Software Engineer)
Autodesk Inc
 Cross Lanes, Guildford, Surrey
 England


Quote:
> What are you trying ? To set the window border style ?
> Maybe you can try to catch the WM_SIZING event.

> Gabriel.


> > Hi i have a problem with removing the resize capability from the main
> > window. Can anyone tell me how this is done?

> > thanx
> > /Anders



Sun, 21 Oct 2001 03:00:00 GMT  
 How to remove rezise capability
The easiest way is by placing the code in your mainframe's Precreate
Window

   BOOL CMainFrame::PreCreateWindow(CREATESTRUCT & cs)
   {

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

          // Remove the sizing frame style bit from the window

           cs.style &= ~WS_THICKFRAME;
           return TRUE;
   }

Charles Steinhardt[MVP]
(To Email: remove NO_SPAM_NO from return address)



Tue, 23 Oct 2001 03:00:00 GMT  
 How to remove rezise capability
Mark,

The easiest way is by placing the code in your mainframe's Precreate
Window

   BOOL CMainFrame::PreCreateWindow(CREATESTRUCT & cs)
   {

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

          // Remove the sizing frame style bit from the window

           cs.style &= ~WS_THICKFRAME;
           return TRUE;
   }

Charles Steinhardt[MVP]
(To Email: remove NO_SPAM_NO from return address)



Tue, 23 Oct 2001 03:00:00 GMT  
 
 [ 7 post ] 

 Relevant Pages 

1. how to remove resize capability

2. how can I rezise a database field ?

3. scripting capabilities

4. ADV: eValid Includes Major New Capabilities in Version 4.0

5. C's capabilities

6. C Compilers with GUI capability?

7. VCCE capabilities

8. editing program to contain MIDI capability

9. C compilers which use full '486 capability

10. C's Limited Macro Capabilities

11. Representation of unions on capability machines

12. Compiler capabilities, and C semantics (was: Style: multiple returns and relatives)

 

 
Powered by phpBB® Forum Software