Solved

Customizing CFileDialog (!)

Posted on 1999-01-12
4
458 Views
Last Modified: 2013-11-20
I'm trying to customize the regular File open/ save as dialog box!
-I have to change the layout a bit, add a bitmap in the background etc. etc. -DON'T ask why! :)

I have had no problems with making my own class which inherits from CFileDialog, and I've even been able to make it process CFileDialog's messages, but that's as far as I've been able to go.. pretty new with MFC..

I want to access the resource of the dialog. -change it, and maybe add a control or two.

Can I somehow access control-variables of the controls? -What are their names?

Can I make a new dialog for the class to use? -In that case; what resource ID's must the controls have in order for the superclass to be able to use them? Where can I find that information?

Thanks beforehand
/Torbjörn Josefsson
0
Comment
Question by:toblo
4 Comments
 
LVL 3

Expert Comment

by:plaroche
Comment Utility
Microsoft Systems Journal, january 1998, C++ Q&A Section.

There is a good example of this, explains all the things you need to know about the file dialog.

If you can't find the article at www.msj.com, post a comment here with your email, I'll send it to you.
0
 

Author Comment

by:toblo
Comment Utility
Thanks for the tip, but the article doesn't tell me how I can access the dialog-resources or the controls.. in fact it says that the code supplied will not work! :)

I think I would need the resource ID's or something. -Wish I could give you the points, but I can't afford it for anything less than an answer.
0
 
LVL 4

Accepted Solution

by:
nil_dib earned 100 total points
Comment Utility
You can acces the contols with GetDlgItem().
With this method you can get the pointer to the combobox, editfield ...
The names for the controls are in <dlgs.h>
Don't forget to include this file.
Look also at www.codeguru.com for CFileDialog derived classes such
as bitmap preview dialogs.
0
 

Expert Comment

by:wwwky
Comment Utility
you can create an own dlg and  plus in the file open/save dialog in it.
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
move a line in eclipse 3 60
zeroFront challenge 7 70
fix34  challenge 9 95
Detect file exist or not 3 76
Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now