Solved

Add menu to CPropertySheet

Posted on 2006-10-25
5
556 Views
Last Modified: 2008-02-01
I have a CPropertySheet that has five pages (CPropertyPages).  I want to add a file menu (with "Open", "Save", "Save As", etc) to the property sheet.  I can't add the menu during design time because the "Menu" option in the resource editor is greyed out (for each property page's "Dialog Properties" page).  Besides, I'd want to add the menu to the property sheet, not the individual pages.  Any thoughts?  Thanks very much.
0
Comment
Question by:clintMon
  • 3
  • 2
5 Comments
 

Author Comment

by:clintMon
ID: 17803257
I'd wrote: " I can't add the menu during design time because the "Menu" option in the resource editor is greyed out".  I meant that I can't add the menu IN THE RESOURCE EDITOR during design time.
0
 
LVL 86

Expert Comment

by:jkr
ID: 17805498
>>I can't add the menu during design time because the "Menu" option in the resource editor is greyed out

That is grayed out because a Property Sheet technically is a dialog, and dialogs don't have menus (caution: don't confuse that with dialog based apps) according to the Windows GUI styleguides. And I might add that this idea also does not "feel" right to me. Why not implementing that as buttons, like it is usually done in these cases?
0
 

Author Comment

by:clintMon
ID: 17806243
OK.  I'm good with buttons instead of a menu (button for "Save", button for "Open File").  Is there a way to add the buttons to CPropertySheet?  This way, the buttons would be available on all of the Property Pages that my property sheet contains.
0
 
LVL 86

Accepted Solution

by:
jkr earned 500 total points
ID: 17806278
Actually, you can almost add anything you want, see e.g. http://www.codeproject.com/property/hacking_the_cpropertyshee.asp ("Hacking the CPropertySheet")
0
 

Author Comment

by:clintMon
ID: 17806350
Perfect, it's what I want, and much more actually.  I was thinking about using the apply button for one of my file features (open file or save file), and this article covers that.  Thanks.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

708 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

23 Experts available now in Live!

Get 1:1 Help Now