[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

loading popup menu from resource

Posted on 1998-05-04
2
Medium Priority
?
265 Views
Last Modified: 2013-11-20
hi, i need a right-click menu in my app. if i create the CMenu using CreatePopupMenu() and add the items at runtime, everything works fine. but i'd like to load the menu from the resource. but when i use the Loadmenu() function to load the menu from the resource, it is not being displayed properly. i only get a thin vertical strip whose height depends on the number of items in the menu but whose width is always around 10-20 pixels which is not enough to display the text. please help me out if you know a solution.
--thanks
Rajesh Vijayakumar
0
Comment
Question by:vijayk
2 Comments
 
LVL 7

Accepted Solution

by:
galkin earned 400 total points
ID: 1307183
After you call LoadMenu you should call GetSubMenu to extract appropriate submenu you want to track as popup.
0
 

Author Comment

by:vijayk
ID: 1307184
it worked! thanks
i had tried with just the menu bar with all the items (the "View as popup" option in the menu editor had me thinking that internally a menu bar and poup menu are same and that i could use the menubar itself as a popup menu but i was wrong)
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
This Micro Tutorial will teach you how to add a cinematic look to any film or video out there. There are very few simple steps that you will follow to do so. This will be demonstrated using Adobe Premiere Pro CS6.
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.
Suggested Courses
Course of the Month17 days, 23 hours left to enroll

830 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