Click here to Skip to main content
15,908,581 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: how to display text in a combo box edit control Pin
elephantstar18-May-06 11:02
elephantstar18-May-06 11:02 
AnswerRe: how to display text in a combo box edit control Pin
Andy Rama19-May-06 3:04
Andy Rama19-May-06 3:04 
GeneralRe: how to display text in a combo box edit control Pin
elephantstar23-May-06 11:45
elephantstar23-May-06 11:45 
QuestionMemory leak issue Pin
Chris Corben18-May-06 8:55
Chris Corben18-May-06 8:55 
AnswerRe: Memory leak issue Pin
Chris Meech18-May-06 9:11
Chris Meech18-May-06 9:11 
GeneralRe: Memory leak issue Pin
Chris Corben18-May-06 12:08
Chris Corben18-May-06 12:08 
AnswerRe: Memory leak issue Pin
knoxplusplus23-May-06 8:03
knoxplusplus23-May-06 8:03 
QuestionDocument Types Pin
BlitzPackage18-May-06 7:46
BlitzPackage18-May-06 7:46 
I have three document types in my software. However, when I run the app, it prompts me to decide what type of document to start with; furthermore when I try to use the same resource ID for more than one of my document templates...it also seems to do the same thing. Any ideas? The offending code is listed below.

Thanks in advance.

<br />
//CMultiDocTemplate* pDocTemplate;<br />
	pDocTemplate = new CMultiDocTemplate(IDR_PhotonOneTYPE,<br />
		RUNTIME_CLASS(CPhotonOneDoc),<br />
		RUNTIME_CLASS(CChildFrame), // custom MDI child frame<br />
		RUNTIME_CLASS(CPhotonOneView));<br />
	if (!pDocTemplate)<br />
		return FALSE;<br />
	AddDocTemplate(pDocTemplate);<br />
	// LyghtWayve Document Template<br />
	//CMultiDocTemplate* pLWDocTemplate;<br />
	pLWDocTemplate = new CMultiDocTemplate(IDR_MAINFRAME,<br />
		RUNTIME_CLASS(CLyghtWayveDoc),<br />
		RUNTIME_CLASS(CLyghtWayveFrm),<br />
		RUNTIME_CLASS(CLyghtWayveView));<br />
	if(!pLWDocTemplate)<br />
		return FALSE;<br />
	AddDocTemplate(pLWDocTemplate);<br />
	// Nuon Document Template<br />
	//CMultiDocTemplate* pNuDocTemplate;<br />
	pNuDocTemplate = new CMultiDocTemplate(IDR_PhotonOneTYPE,<br />
		RUNTIME_CLASS(CNuonDoc),<br />
		RUNTIME_CLASS(CNuonFrm),<br />
		RUNTIME_CLASS(CNuonFormView));<br />
	if(!pNuDocTemplate)<br />
		return FALSE;<br />
	AddDocTemplate(pNuDocTemplate);<br />
<br />
<br />
	// create main MDI Frame window<br />
	CMainFrame* pMainFrame = new CMainFrame;<br />
	if (!pMainFrame || !pMainFrame->LoadFrame(IDR_MAINFRAME))<br />
		return FALSE;<br />
	m_pMainWnd = pMainFrame;<br />
	// call DragAcceptFiles only if there's a suffix<br />
	//  In an MDI app, this should occur immediately after setting m_pMainWnd<br />
	// Enable drag/drop open<br />
	m_pMainWnd->DragAcceptFiles();<br />
	// Enable DDE Execute open<br />
	EnableShellOpen();<br />
	RegisterShellFileTypes(TRUE);<br />
	// Parse command line for standard shell commands, DDE, file open<br />
	CCommandLineInfo cmdInfo;<br />
	ParseCommandLine(cmdInfo);<br />
	// Dispatch commands specified on the command line.  Will return FALSE if<br />
	// app was launched with /RegServer, /Register, /Unregserver or /Unregister.<br />
	if (!ProcessShellCommand(cmdInfo))<br />
		return FALSE;<br />
	// The main window has been initialized, so show and update it<br />
	pMainFrame->ShowWindow(m_nCmdShow);<br />
	pMainFrame->UpdateWindow();<br />


-- modified at 13:46 Thursday 18th May, 2006
AnswerRe: Document Types Pin
David Crow18-May-06 9:18
David Crow18-May-06 9:18 
GeneralRe: Document Types Pin
BlitzPackage18-May-06 10:07
BlitzPackage18-May-06 10:07 
Questionstdafx Pin
big_denny_20018-May-06 6:59
big_denny_20018-May-06 6:59 
AnswerRe: stdafx Pin
Michael Dunn18-May-06 7:36
sitebuilderMichael Dunn18-May-06 7:36 
AnswerRe: stdafx Pin
knoxplusplus23-May-06 8:05
knoxplusplus23-May-06 8:05 
QuestionMMC-Adding an Item to the context menu of the Results Pane Pin
Stevemc7518-May-06 5:46
Stevemc7518-May-06 5:46 
QuestionCRecordset Timing Problem Pin
e-DJ18-May-06 5:16
e-DJ18-May-06 5:16 
QuestionCRecordset and CTime Problem Pin
e-DJ18-May-06 5:09
e-DJ18-May-06 5:09 
QuestionRe: CRecordset and CTime Problem Pin
David Crow18-May-06 5:54
David Crow18-May-06 5:54 
QuestionRe: CRecordset and CTime Problem Pin
e-DJ19-May-06 2:57
e-DJ19-May-06 2:57 
AnswerRe: CRecordset and CTime Problem Pin
David Crow19-May-06 3:03
David Crow19-May-06 3:03 
GeneralRe: CRecordset and CTime Problem Pin
e-DJ23-May-06 5:51
e-DJ23-May-06 5:51 
QuestionError not releasing memeory Pin
bujji_bec18-May-06 4:50
bujji_bec18-May-06 4:50 
AnswerRe: Error not releasing memeory Pin
NiceNaidu18-May-06 4:58
NiceNaidu18-May-06 4:58 
AnswerRe: Error not releasing memeory Pin
led mike18-May-06 4:59
led mike18-May-06 4:59 
GeneralRe: Error not releasing memeory Pin
Cedric Moonen18-May-06 5:07
Cedric Moonen18-May-06 5:07 
GeneralRe: Error not releasing memeory Pin
led mike18-May-06 5:46
led mike18-May-06 5:46 

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.