Click here to Skip to main content
15,905,504 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: program too big for mem Pin
Willem B6-Feb-03 4:33
Willem B6-Feb-03 4:33 
GeneralRe: program too big for mem Pin
AlexO6-Feb-03 4:48
AlexO6-Feb-03 4:48 
GeneralRe: program too big for mem Pin
stv6-Feb-03 17:24
stv6-Feb-03 17:24 
GeneralRe: program too big for mem Pin
Ted Ferenc6-Feb-03 7:46
Ted Ferenc6-Feb-03 7:46 
GeneralEncrypting technique for simple CString Pin
Willem B6-Feb-03 4:29
Willem B6-Feb-03 4:29 
GeneralRe: Encrypting technique for simple CString Pin
Chris Losinger6-Feb-03 5:01
professionalChris Losinger6-Feb-03 5:01 
GeneralRe: Encrypting technique for simple CString Pin
Miguel Ortiz6-Feb-03 8:43
Miguel Ortiz6-Feb-03 8:43 
GeneralCSplitterWnd is evil! Pin
SomeUser6-Feb-03 3:47
SomeUser6-Feb-03 3:47 
Hi
I'm trying to create a CSplitterWnd within a CFrameWnd, but I have some problems with that... or MFC. I'm creating the CFrameWnd by calling the Create function, and passing a NULL to the pContext parameter because i don't know how to fill the CCreateContext with valid data.
But my problems starts in the OnCreateClient of the CFrameWnd, when i'm trying to create the CSplitterWnd.

Doing something like this:

<br />
BOOL CMyFrameWnd::OnCreateClient(LPCREATESTRUCT lpcs, CCreateContext* pContext)<br />
{<br />
 <br />
 <br />
	m_MySplitterWnd.CreateStatic (this, 2, 1);<br />
<br />
  	m_MySplitterWnd.CreateView (0, 0, RUNTIME_CLASS(CMyView), CSize(100,100), pContext);<br />
	m_MySplitterWnd.CreateView (1, 0, RUNTIME_CLASS(CMyView), CSize(100,100), pContext);<br />
  <br />
<br />
	return TRUE;<br />
}<br />


As expected, the pContex is NULL and apparently i'm not allowed to call CreateView and pass NULL to the pContext. CreateView returns FALSE, and after that i'm getting a bunch of assertions and an access violation. So what am i supposed to do to get this to work?
GeneralRe: CSplitterWnd is evil! Pin
Zdeslav Vojkovic6-Feb-03 5:54
Zdeslav Vojkovic6-Feb-03 5:54 
GeneralRe: CSplitterWnd is evil! Pin
SomeUser6-Feb-03 7:03
SomeUser6-Feb-03 7:03 
GeneralRegistry Reading with CRegKey Pin
naradaji6-Feb-03 3:42
naradaji6-Feb-03 3:42 
GeneralRe: Registry Reading with CRegKey Pin
naradaji6-Feb-03 4:04
naradaji6-Feb-03 4:04 
Generalcreating a grayscale "rainbow" in code Pin
ns6-Feb-03 3:17
ns6-Feb-03 3:17 
GeneralRe: creating a grayscale "rainbow" in code Pin
David Chamberlain6-Feb-03 10:18
David Chamberlain6-Feb-03 10:18 
GeneralRe: creating a grayscale "rainbow" in code Pin
ns7-Feb-03 5:05
ns7-Feb-03 5:05 
GeneralRe: Windows Service and MAPIInitialize() Pin
6-Feb-03 3:08
suss6-Feb-03 3:08 
GeneralRecurrence detection Pin
RChin6-Feb-03 2:09
RChin6-Feb-03 2:09 
Generalwhat is the question? Pin
6-Feb-03 2:34
suss6-Feb-03 2:34 
GeneralRe: what is the question? Pin
RChin6-Feb-03 3:43
RChin6-Feb-03 3:43 
GeneralRe: what is the question? Pin
AlexO6-Feb-03 4:08
AlexO6-Feb-03 4:08 
GeneralPrgramatic Control of Toolbar Pin
Jawache6-Feb-03 1:51
Jawache6-Feb-03 1:51 
GeneralRe: Prgramatic Control of Toolbar Pin
KarstenK6-Feb-03 2:23
mveKarstenK6-Feb-03 2:23 
GeneralRe: Prgramatic Control of Toolbar Pin
Jawache6-Feb-03 3:48
Jawache6-Feb-03 3:48 
GeneralGradient Progress Bar Pin
Ambit6-Feb-03 1:50
Ambit6-Feb-03 1:50 
GeneralRe: Gradient Progress Bar Pin
Kayembi6-Feb-03 9:04
Kayembi6-Feb-03 9:04 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.