Solved

Modeless dialog and accelerators

Posted on 1997-04-23
5
341 Views
Last Modified: 2013-11-20
I've got some modeless dialogs inside a CFormView (like a CPropertyPage/Sheet). The accelerators don't work when focus is on one of the dialogs.
Any idea how I can make them work?
0
Comment
Question by:roar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 2

Accepted Solution

by:
rajesh032097 earned 70 total points
ID: 1301164
Hi,
Try the following:
Set the "control" property for each of your dialog which you are using inside the CFormView. This property is available in the "More Styles" tab of the dialog properties in the VC++ dialog editor.
0
 

Author Comment

by:roar
ID: 1301165
I really expected that to work, given the description of the control property in the online help. I applied the control property to the dialogs, but unfortunately I still got the same problem. If you made it work, can you give me some details on what you did?
0
 
LVL 2

Expert Comment

by:rajesh032097
ID: 1301166
Can you elaborate on how exactly you are using the form view? I had the same problem and got solved by setting the "control" property. One more thing which also worked with me is setting "control parent" property in "extended styles" tab. But if your dialogs are derived from CPropertyPage, then this won't work since Property pages donot yet support dialog templates with extended styles.  
Hope this works.
0
 
LVL 2

Expert Comment

by:rajesh032097
ID: 1301167
Hi again,
Please also refer to "using accelerators in modeless dialogs" article in MFC knowledge base.
If you have any problems with it, get back to me.
0
 

Author Comment

by:roar
ID: 1301168
I added a PreTranslateMessage as described in the article, and it worked beatifully. Thanks.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
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 …
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.
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.

635 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