Click here to Skip to main content
15,902,189 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionIs it good practice to use TRY-CATCH in this way? Pin
paresh_joe10-Nov-08 23:33
paresh_joe10-Nov-08 23:33 
AnswerRe: Is it good practice to use TRY-CATCH in this way? Pin
Hector_M11-Nov-08 0:34
Hector_M11-Nov-08 0:34 
AnswerRe: Is it good practice to use TRY-CATCH in this way? Pin
bulg11-Nov-08 7:42
bulg11-Nov-08 7:42 
QuestionProblem occur to access dll dialog box Pin
ShilpiP10-Nov-08 23:20
ShilpiP10-Nov-08 23:20 
AnswerRe: Problem occur to access dll dialog box Pin
SandipG 10-Nov-08 23:26
SandipG 10-Nov-08 23:26 
GeneralRe: Problem occur to access dll dialog box Pin
ShilpiP10-Nov-08 23:49
ShilpiP10-Nov-08 23:49 
AnswerRe: Problem occur to access dll dialog box Pin
CPallini10-Nov-08 23:27
mveCPallini10-Nov-08 23:27 
GeneralRe: Problem occur to access dll dialog box Pin
ShilpiP10-Nov-08 23:47
ShilpiP10-Nov-08 23:47 
Thanks For your reply Pallini
After debugging the dll i knew that the crash occur when i domodal the dialog of dll.
Here is my code. ConfigurationCapture is exported function.
CConfigDlg is class having base class CDialog.
BOOL CCaptureScreen::ConfigureCapture(HWND hWndParent, CaptureData* lpData)
{
	ASSERT(lpData);
	if (!lpData)
		return(FALSE);
	lpData->bCaptureFullScreen = FALSE;
	strcpy_s(lpData->szCaptureFilename,strlen(lpData->szCaptureFilename),"");
	strcpy_s(lpData->szCapturePath,strlen(lpData->szCapturePath),"");
	
	AFX_MANAGE_STATE(AfxGetStaticModuleState());
	dlg = new CConfigDlg(lpData->bCaptureFullScreen, CA2T(lpData->szCapturePath));
	//CConfigDlg dlg(lpData->bCaptureFullScreen, CA2T(lpData->szCapturePath));
	//CConfigDlg dlg;
	BOOL bStat = FALSE;
	if (dlg->DoModal() == IDOK) {--->Crash (UNHANDLED EXCEPTION)
		bStat = TRUE;
		lpData->bCaptureFullScreen = dlg->m_nFullScreen > 0;
		strncpy_s(lpData->szCapturePath, MAX_PATH, CT2A(dlg->m_strPath), _TRUNCATE);
		*lpData->szCaptureFilename = '\0';
	}
	return(bStat);
}


Yes U Can ...If U Can ,Dream it , U can do it ...ICAN

GeneralRe: Problem occur to access dll dialog box Pin
Mark Salsbery11-Nov-08 6:24
Mark Salsbery11-Nov-08 6:24 
GeneralRe: Problem occur to access dll dialog box Pin
ShilpiP11-Nov-08 18:11
ShilpiP11-Nov-08 18:11 
GeneralRe: Problem occur to access dll dialog box Pin
Mark Salsbery11-Nov-08 18:15
Mark Salsbery11-Nov-08 18:15 
GeneralRe: Problem occur to access dll dialog box Pin
ShilpiP11-Nov-08 18:45
ShilpiP11-Nov-08 18:45 
GeneralRe: Problem occur to access dll dialog box Pin
Mark Salsbery11-Nov-08 18:52
Mark Salsbery11-Nov-08 18:52 
GeneralRe: Problem occur to access dll dialog box Pin
ShilpiP11-Nov-08 19:18
ShilpiP11-Nov-08 19:18 
GeneralRe: Problem occur to access dll dialog box Pin
Mark Salsbery11-Nov-08 20:28
Mark Salsbery11-Nov-08 20:28 
GeneralRe: Problem occur to access dll dialog box Pin
ShilpiP12-Nov-08 18:04
ShilpiP12-Nov-08 18:04 
GeneralRe: Problem occur to access dll dialog box Pin
Mark Salsbery12-Nov-08 20:47
Mark Salsbery12-Nov-08 20:47 
QuestionHow to return multiple values in MFC ActiveX? Pin
followait10-Nov-08 22:51
followait10-Nov-08 22:51 
AnswerRe: How to return multiple values in MFC ActiveX? Pin
Roger Stoltz10-Nov-08 23:05
Roger Stoltz10-Nov-08 23:05 
GeneralRe: How to return multiple values in MFC ActiveX? Pin
followait10-Nov-08 23:24
followait10-Nov-08 23:24 
AnswerRe: How to return multiple values in MFC ActiveX? Pin
Roger Stoltz11-Nov-08 0:15
Roger Stoltz11-Nov-08 0:15 
GeneralRe: How to return multiple values in MFC ActiveX? Pin
followait11-Nov-08 15:56
followait11-Nov-08 15:56 
QuestionRe: How to return multiple values in MFC ActiveX? Pin
Roger Stoltz11-Nov-08 22:15
Roger Stoltz11-Nov-08 22:15 
AnswerRe: How to return multiple values in MFC ActiveX? Pin
followait12-Nov-08 3:04
followait12-Nov-08 3:04 
AnswerRe: How to return multiple values in MFC ActiveX? Pin
Roger Stoltz12-Nov-08 3:20
Roger Stoltz12-Nov-08 3:20 

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.