Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - Problem of SplitterWnd
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Problem of SplitterWnd

 Post Reply Post Reply
Author
Message
qinzhw View Drop Down
Newbie
Newbie


Joined: 25 November 2005
Location: Colombia
Status: Offline
Points: 16
Post Options Post Options   Thanks (0) Thanks(0)   Quote qinzhw Quote  Post ReplyReply Direct Link To This Post Topic: Problem of SplitterWnd
    Posted: 30 November 2005 at 2:57am

I want to create a extendable application UI like the TabbedView Sample. In which I can attach any window object to a tabcontrol,such as CView object,CHtmlView Object, CFormView object , FrameWnd Object etc. Let's pretend we don't know what exactly the object's class,we just know it's  CWnd-based, so if the object is FrameWnd-based, we should splitter it by a CSplitterWnd member. How to do that ? I mean how to add a splittered Frame to a tabcontrol? It seems hard.

Back to Top
qinzhw View Drop Down
Newbie
Newbie


Joined: 25 November 2005
Location: Colombia
Status: Offline
Points: 16
Post Options Post Options   Thanks (0) Thanks(0)   Quote qinzhw Quote  Post ReplyReply Direct Link To This Post Posted: 30 November 2005 at 3:54am

This problem has been resolved.

By default , a CView-based class generated by MFC has a protected constructor, 
when using CRuntimeClass::CreateObject() to creating an instance of such class, return value is null.  Just define the constructor as a public one CSplitterWnd::AddView will return OK.

 

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.031 seconds.