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

C / C++ / MFC

 
GeneralRe: DLL and CBitmap Pin
gucy13-Jun-03 19:07
gucy13-Jun-03 19:07 
GeneralHelp with GUI Design in VC++ .NET Pin
James A Beggs13-Jun-03 10:31
James A Beggs13-Jun-03 10:31 
GeneralPostNcDestroy problems Pin
andyg.10113-Jun-03 10:24
andyg.10113-Jun-03 10:24 
GeneralRe: PostNcDestroy problems Pin
David Crow13-Jun-03 10:41
David Crow13-Jun-03 10:41 
GeneralRe: PostNcDestroy problems Pin
John M. Drescher13-Jun-03 10:46
John M. Drescher13-Jun-03 10:46 
GeneralRe: PostNcDestroy problems Pin
andyg.10113-Jun-03 10:51
andyg.10113-Jun-03 10:51 
GeneralRe: PostNcDestroy problems Pin
John M. Drescher13-Jun-03 10:54
John M. Drescher13-Jun-03 10:54 
GeneralRe: PostNcDestroy problems Pin
andyg.10113-Jun-03 10:58
andyg.10113-Jun-03 10:58 
It's definetly modeless, I create a new dialogue like this
if(!m_pDlgComms) // check to see if the dialogue exists
		{
		m_pDlgComms = new CCommsDlg(this);

etc
which is then constructed like this
CCommsDlg::CCommsDlg(CWnd* pParent /*=NULL*/)
	: CDialog(CCommsDlg::IDD, pParent)
{
	//{{AFX_DATA_INIT(CCommsDlg)
	m_sCommsInput = _T("");
	m_sCommsOutput = _T("");
	//}}AFX_DATA_INIT
	if (Create(CCommsDlg::IDD, pParent))
	{ 
	m_pParent = pParent;
	ShowWindow(SW_SHOW);
	}
}

and here is the PostNcDestroy which is called whenever I force a destroy window using a button for example
void CCommsDlg::PostNcDestroy() 
{
	// TODO: Add your specialized code here and/or call the base class
	CDialog::PostNcDestroy();
	if(m_pParent)
	{	
			
		((CBuggycontrolappView*)m_pParent)->m_pDlgComms			= NULL;
		((CBuggycontrolappView*)m_pParent)->m_nCommsToggleState = 0;
	}
	delete this;
}

but not when I use the cross. Even though there is a WM_CLOSE message
Andy
GeneralRe: PostNcDestroy problems Pin
John M. Drescher13-Jun-03 11:09
John M. Drescher13-Jun-03 11:09 
GeneralRe: PostNcDestroy problems Pin
Toni7813-Jun-03 18:01
Toni7813-Jun-03 18:01 
GeneralRe: PostNcDestroy problems Pin
andyg.10113-Jun-03 22:21
andyg.10113-Jun-03 22:21 
GeneralRe: PostNcDestroy problems Pin
Toni7813-Jun-03 23:05
Toni7813-Jun-03 23:05 
GeneralOnDestroy called for base class first... Pin
Miszou13-Jun-03 8:24
Miszou13-Jun-03 8:24 
GeneralRe: OnDestroy called for base class first... Pin
valikac13-Jun-03 9:39
valikac13-Jun-03 9:39 
GeneralRe: OnDestroy called for base class first... Pin
Miszou13-Jun-03 9:49
Miszou13-Jun-03 9:49 
Generalproblem with passing STL variables across the DLL boundaries Pin
Anonymous13-Jun-03 7:56
Anonymous13-Jun-03 7:56 
GeneralRe: problem with passing STL variables across the DLL boundaries Pin
Chris Losinger13-Jun-03 9:23
professionalChris Losinger13-Jun-03 9:23 
GeneralRe: problem with passing STL variables across the DLL boundaries Pin
Anonymous13-Jun-03 12:05
Anonymous13-Jun-03 12:05 
GeneralRe: problem with passing STL variables across the DLL boundaries Pin
Anonymous13-Jun-03 12:10
Anonymous13-Jun-03 12:10 
GeneralRe: problem with passing STL variables across the DLL boundaries Pin
Anonymous15-Jun-03 17:01
Anonymous15-Jun-03 17:01 
Generalreading file 's header Pin
pnpfriend13-Jun-03 7:18
pnpfriend13-Jun-03 7:18 
GeneralRe: reading file 's header Pin
David Crow13-Jun-03 7:29
David Crow13-Jun-03 7:29 
GeneralRe: reading file 's header Pin
pnpfriend13-Jun-03 8:33
pnpfriend13-Jun-03 8:33 
GeneralRe: reading file 's header Pin
David Crow13-Jun-03 8:41
David Crow13-Jun-03 8:41 
GeneralRe: reading file 's header Pin
pnpfriend13-Jun-03 8:54
pnpfriend13-Jun-03 8:54 

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.