Click here to Skip to main content
15,883,825 members
Articles / Desktop Programming / MFC

FolderBrowse

Rate me:
Please Sign up or sign in to vote.
4.50/5 (12 votes)
7 Sep 2005 64.3K   1.9K   45  
Browse to a folder.
// -----------------
// FolderBrowseDlg.h
// -----------------
/**
* @file
* @brief Re: CFolderBrowseDlg
* @author Achim Klein
* @version 0.1
*/


// -------------------
// One-Definition-Rule
// -------------------
#ifndef FOLDERBROWSEDLG_H_INCLUDE_NR1
#define FOLDERBROWSEDLG_H_INCLUDE_NR1


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


// ----------------------------------------
// Definition of the CFolderBrowseDlg class
// ----------------------------------------
/**
 * The main window.
 */
class CFolderBrowseDlg : public CDialog
{

public:

	// ------------
	// Construction
	// ------------

	/// standard-constructor
	CFolderBrowseDlg(CWnd* pParent = NULL);


	// -----------
	// Dialog Data
	// -----------
	//{{AFX_DATA(CFolderBrowseDlg)
	enum { IDD = IDD_FOLDERBROWSE_DIALOG };
	CString	m_folder;
	//}}AFX_DATA


	// --------------------------
	// Overloaded virtual methods
	// --------------------------
	//{{AFX_VIRTUAL(CFolderBrowseDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);
	//}}AFX_VIRTUAL


protected:

	// ----------------
	// Internal methods
	// ----------------

	/// moves the controls on sizing
	void doMoveControls();


	// ----------
	// Attributes
	// ----------

	// the application's icon
	HICON m_hIcon;


	// ---------------------
	// Message map functions
	// ---------------------
	//{{AFX_MSG(CFolderBrowseDlg)
	virtual BOOL OnInitDialog();
	afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	afx_msg void OnBrowse();
	afx_msg void OnSize(UINT nType, int cx, int cy);
	afx_msg void OnGetMinMaxInfo(MINMAXINFO FAR* lpMMI);
	//}}AFX_MSG

	DECLARE_MESSAGE_MAP()
};


#endif	// #ifndef FOLDERBROWSEDLG_H_INCLUDE_NR1

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
Web Developer
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