Click here to Skip to main content
15,912,329 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: VC++ Skinnning Pin
Hamid_RT19-Sep-08 23:21
Hamid_RT19-Sep-08 23:21 
GeneralRe: VC++ Skinnning Pin
john563219-Sep-08 23:36
john563219-Sep-08 23:36 
GeneralRe: VC++ Skinnning Pin
Hamid_RT20-Sep-08 0:51
Hamid_RT20-Sep-08 0:51 
QuestionCString assignment problem with char * if char* have a '\0' EOS as a data Pin
ravimalikmca19-Sep-08 22:40
ravimalikmca19-Sep-08 22:40 
AnswerRe: CString assignment problem with char * if char* have a '\0' EOS as a data Pin
Cedric Moonen19-Sep-08 23:30
Cedric Moonen19-Sep-08 23:30 
AnswerRe: CString assignment problem with char * if char* have a '\0' EOS as a data Pin
Gary R. Wheeler20-Sep-08 1:41
Gary R. Wheeler20-Sep-08 1:41 
AnswerRe: CString assignment problem with char * if char* have a '\0' EOS as a data Pin
CPallini20-Sep-08 22:13
mveCPallini20-Sep-08 22:13 
QuestionError Printing Pin
Max++19-Sep-08 20:38
Max++19-Sep-08 20:38 
My project is SDI that first view is CFromView derive class.
Then I add second view with CScrollView derive class.
In this view I want to print out the data So I add this function

BOOL CReportView::OnPreparePrinting(CPrintInfo* pInfo)
{
	CPrintDialog *dlg = new CPrintDialog(FALSE, PD_PAGENUMS);
	pInfo->m_pPD = dlg;
	pInfo->SetMinPage(1);
	pInfo->SetMaxPage(1);

	
	return DoPreparePrinting(pInfo);

}

while I run this function I got exception error at

BOOL CDialog::Create(LPCTSTR lpszTemplateName, CWnd* pParentWnd) 


in file "dlgcore.cpp"

BOOL CDialog::Create(LPCTSTR lpszTemplateName, CWnd* pParentWnd)
{
	ASSERT(IS_INTRESOURCE(lpszTemplateName) ||
		AfxIsValidString(lpszTemplateName));

	m_lpszTemplateName = lpszTemplateName;  // used for help
	if (IS_INTRESOURCE(m_lpszTemplateName) && m_nIDHelp == 0)
		m_nIDHelp = LOWORD((DWORD_PTR)m_lpszTemplateName);

#ifdef _DEBUG
	if (!_AfxCheckDialogTemplate(lpszTemplateName, FALSE))
	{
Error Here >>>> ASSERT(FALSE);          // invalid dialog template name
		PostNcDestroy();        // cleanup if Create fails too soon
		return FALSE;
	}
#endif //_DEBUG

	HINSTANCE hInst = AfxFindResourceHandle(lpszTemplateName, RT_DIALOG);
	HRSRC hResource = ::FindResource(hInst, lpszTemplateName, RT_DIALOG);
	HGLOBAL hTemplate = LoadResource(hInst, hResource);
	BOOL bResult = CreateIndirect(hTemplate, pParentWnd, hInst);
	FreeResource(hTemplate);

	return bResult;
}


Please help me to solve this problem
Questionerasing an element from a static vector. Pin
steph519-Sep-08 8:29
steph519-Sep-08 8:29 
AnswerRe: erasing an element from a static vector. Pin
Mark Salsbery19-Sep-08 9:14
Mark Salsbery19-Sep-08 9:14 
GeneralRe: erasing an element from a static vector. Pin
steph519-Sep-08 10:00
steph519-Sep-08 10:00 
QuestionSTL string formatting Pin
Trollslayer19-Sep-08 7:00
mentorTrollslayer19-Sep-08 7:00 
AnswerRe: STL string formatting Pin
CPallini19-Sep-08 7:28
mveCPallini19-Sep-08 7:28 
GeneralRe: STL string formatting Pin
Saurabh.Garg20-Sep-08 2:56
Saurabh.Garg20-Sep-08 2:56 
GeneralRe: STL string formatting Pin
CPallini20-Sep-08 22:11
mveCPallini20-Sep-08 22:11 
GeneralRe: STL string formatting Pin
Saurabh.Garg20-Sep-08 23:20
Saurabh.Garg20-Sep-08 23:20 
GeneralRe: STL string formatting Pin
CPallini21-Sep-08 6:05
mveCPallini21-Sep-08 6:05 
AnswerRe: STL string formatting Pin
Cedric Moonen19-Sep-08 7:37
Cedric Moonen19-Sep-08 7:37 
AnswerRe: STL string formatting Pin
David Crow19-Sep-08 8:01
David Crow19-Sep-08 8:01 
Questionsoftware to redirect VGA output Pin
spicy_kid200019-Sep-08 5:21
spicy_kid200019-Sep-08 5:21 
AnswerRe: software to redirect VGA output Pin
Trollslayer19-Sep-08 6:41
mentorTrollslayer19-Sep-08 6:41 
GeneralRe: software to redirect VGA output Pin
spicy_kid200021-Sep-08 19:57
spicy_kid200021-Sep-08 19:57 
QuestionWandering Toolbars Pin
Redeye9219-Sep-08 4:06
Redeye9219-Sep-08 4:06 
QuestionRe: Wandering Toolbars Pin
Mark Salsbery19-Sep-08 5:57
Mark Salsbery19-Sep-08 5:57 
AnswerRe: Wandering Toolbars Pin
Redeye9219-Sep-08 6:15
Redeye9219-Sep-08 6:15 

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.