BCGSuite for MFC
CBCGPFileDialog

Detailed Description

The CBCGPFileDialog class extends the functionality of the CFileDialog and changes its look & feel. The new features include three property pages for opening a new, existing or recent file, integration with document manager and ability to display a logo image.

To use the CBCGPFileDialog class in your application you need to construct a CBCGPFileDialog object first. Then you may want to set a logo bitmap, dialog icon, document types to be shown and provide an image list that should conform the document types the user can create. The document types will be obtained by constructor from the document manager. When you're done with the initialization you should call the DoModal function. If DoModal returns non-zero value the user has pressed OK and you should call GetPage() member function to find out whether the user has chosen to create a new document (CBCGPFileDialog::BCGPFileNew value), open an existing document (CBCGPFileDialog::BCGPFileOpen) or open a recently used document (CBCGPFileDialog::BCGPFileRecent). Finally, you may retrieve the selected document type by GetNewItemIndex(), path to the existing document by GetPathName() or recent file name by GetRecentFilePath() member functions.

Inherits CFileDialog.

Public Types

enum  SelectedPage
 

Public Member Functions

 CBCGPFileDialogConstructor.
 
 AddNewItemAdds a new document type to be shown on the "New File" tab.
 
 GetNewItemIndexReturns the index of the selected item in the "New" tab of the file open dialog.
 
 GetPageReturns the full path of the selected file on the "Recent" page.
 
 GetRecentFilePathReturns the full path of the selected file on the "Recent" page.
 
 SetDlgIconSets the dialog box icon
 
 SetExtraHeightSets the extra dialog box client area height
 
 SetExtraWidthSets the extra width for the dialog box client area
 
 SetLogoBitmapSets a dialog box logo image.
 
 SetNewImagesListProvides the dialog box with the list of images to be associated with document types, displayed in the "New" tab.