Click here to Skip to main content
15,884,353 members
Articles / Desktop Programming / MFC

A thread-safe timed message box

Rate me:
Please Sign up or sign in to vote.
3.43/5 (4 votes)
12 Feb 2001 218.6K   3.5K   50  
The system Message Box that is closed atuomatically after some time
// MsgBoxDemoDlg.h : Header-Datei
//

#if !defined(AFX_MSGBOXDEMODLG_H__E78B502F_D8EE_4B39_8964_E9C93508BAEA__INCLUDED_)
#define AFX_MSGBOXDEMODLG_H__E78B502F_D8EE_4B39_8964_E9C93508BAEA__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

/////////////////////////////////////////////////////////////////////////////
// CMsgBoxDemoDlg Dialogfeld

class CMsgBoxDemoDlg : public CDialog
{
// Konstruktion
public:
	CMsgBoxDemoDlg(CWnd* pParent = NULL);	// Standard-Konstruktor

// Dialogfelddaten
	//{{AFX_DATA(CMsgBoxDemoDlg)
	enum { IDD = IDD_MSGBOXDEMO_DIALOG };
	BOOL	m_bStatus;
	//}}AFX_DATA

	// Vom Klassenassistenten generierte �berladungen virtueller Funktionen
	//{{AFX_VIRTUAL(CMsgBoxDemoDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV-Unterst�tzung
	//}}AFX_VIRTUAL

// Implementierung
protected:
	HICON m_hIcon;

	// Generierte Message-Map-Funktionen
	//{{AFX_MSG(CMsgBoxDemoDlg)
	virtual BOOL OnInitDialog();
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	afx_msg void OnButtonNothread();
	afx_msg void OnButtonThread();
	afx_msg void OnButtonNormal();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ f�gt unmittelbar vor der vorhergehenden Zeile zus�tzliche Deklarationen ein.

#endif // !defined(AFX_MSGBOXDEMODLG_H__E78B502F_D8EE_4B39_8964_E9C93508BAEA__INCLUDED_)

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Germany Germany
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions