Solved

CChildFrame frame border

Posted on 2004-10-08
4
560 Views
Last Modified: 2013-11-20
Hello

How can I change the border of MDI Child frame window. I want to achive very thin border, or better border like in forms of VB applications....

I have already tried but no results:

BOOL CChildFrame::PreCreateWindow(CREATESTRUCT& cs)
{
      // TODO: Modify the Window class or styles here by modifying
      //  the CREATESTRUCT cs
      cs.style&=~(FWS_ADDTOTITLE | WS_THICKFRAME);

      //cs.dwExStyle|=WS_EX_CLIENTEDGE;
      if( !CMDIChildWnd::PreCreateWindow(cs) )
            return FALSE;

      return TRUE;
}

thank you for your help
0
Comment
Question by:LukaKrop
  • 2
  • 2
4 Comments
 

Author Comment

by:LukaKrop
ID: 12258117
Sorry forgot to add:

It must be sizable!!!

thnx
0
 
LVL 13

Accepted Solution

by:
SteH earned 500 total points
ID: 12258420
have you tried the solution given in
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html/_core_Changing_the_Styles_of_a_Window_Created_by_MFC.asp
You need to derive a class from MDIChildWnd where you do the coding you showed.
0
 

Author Comment

by:LukaKrop
ID: 12264655
Which style shoul I change to become a MDIChild window with very thin border, title, sizable.

thnx
0
 
LVL 13

Expert Comment

by:SteH
ID: 12274665
WS_THICKFRAME should be removed. It is then up to you to draw a visible frame which allows the user to identify a place where to size. MFC assumes that thick frames can be resized. But when you design a GUI you are free to change that. There are other applications which to a sizing with a thin border (ie firefox).
0

Featured Post

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Detect CR LF to each line 12 159
post4 challenge 28 100
NotAlone Challenge 20 83
matchUp  challenge 9 106
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question