Click here to Skip to main content
15,926,507 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Restrict my application to one instance only Pin
ThatsAlok3-May-05 21:33
ThatsAlok3-May-05 21:33 
GeneralRe: Restrict my application to one instance only Pin
Claudio Grazioli3-May-05 21:38
Claudio Grazioli3-May-05 21:38 
GeneralRe: Restrict my application to one instance only Pin
Aamir Butt4-May-05 0:58
Aamir Butt4-May-05 0:58 
GeneralRe: Restrict my application to one instance only Pin
Claudio Grazioli4-May-05 1:24
Claudio Grazioli4-May-05 1:24 
GeneralRe: Restrict my application to one instance only Pin
Aamir Butt4-May-05 19:08
Aamir Butt4-May-05 19:08 
GeneralRe: Restrict my application to one instance only Pin
David Crow4-May-05 3:31
David Crow4-May-05 3:31 
GeneralRe: Restrict my application to one instance only Pin
itkid4-May-05 20:54
itkid4-May-05 20:54 
GeneralMenu Pin
Anonymous3-May-05 20:48
Anonymous3-May-05 20:48 
Hi everybody,

I have created an PopUp Menu in a CDialog...it works OK.

Now I want to create a PopUp Menu inside an ActiveX every time I click Button RIGHT of the mouse...
I have copied the code inside the function WM_RBUTTONDOWN...The problem is that it shows the Menu but it is DISABLED (it is shown but I can not select an option).

How can I do it to solve it...to make it enable?Someone has told me that it doesn't work 'cause I need to call a function for each Item of the Menu...but

Thanks

Here the code :


HMENU hMenu = ::CreatePopupMenu();
if (NULL != hMenu)
{
// add a few test items
::AppendMenu(hMenu, MF_ENABLED | MF_STRING , 1, "Change Color");
::AppendMenu(hMenu, MF_ENABLED | MF_STRING , 2, "Hide");
::AppendMenu(hMenu, MF_ENABLED | MF_STRING , 3, "Item 3-");

ClientToScreen(&point);

int sel = ::TrackPopupMenuEx(hMenu,
TPM_CENTERALIGN | TPM_RETURNCMD,
point.x,
point.y,
m_hWnd,
NULL);

CString s;

s.Format("The selected item is %d", sel);
TRACE(s);

::DestroyMenu(hMenu);
GeneralRe: Menu Pin
ThomasABBE4-May-05 1:45
ThomasABBE4-May-05 1:45 
GeneralMultiple http-requests are stuck Pin
meremortal3-May-05 20:44
meremortal3-May-05 20:44 
GeneralRe: Multiple http-requests are stuck Pin
Ravi Bhavnani4-May-05 7:33
professionalRavi Bhavnani4-May-05 7:33 
GeneralRe: Multiple http-requests are stuck Pin
meremortal9-May-05 10:39
meremortal9-May-05 10:39 
GeneralRe: Multiple http-requests are stuck Pin
Ravi Bhavnani9-May-05 10:52
professionalRavi Bhavnani9-May-05 10:52 
GeneralRe: Multiple http-requests are stuck Pin
geo_m12-May-05 9:10
geo_m12-May-05 9:10 
GeneralRe: Multiple http-requests are stuck Pin
meremortal12-May-05 10:10
meremortal12-May-05 10:10 
GeneralRe: Multiple http-requests are stuck Pin
geo_m13-May-05 7:49
geo_m13-May-05 7:49 
GeneralJava Launcher Pin
vyjesh3-May-05 20:34
vyjesh3-May-05 20:34 
GeneralRe: Java Launcher Pin
S. Senthil Kumar3-May-05 20:37
S. Senthil Kumar3-May-05 20:37 
Generala question on heap..... Pin
namaskaaram3-May-05 20:14
namaskaaram3-May-05 20:14 
GeneralRe: a question on heap..... Pin
RYU^^3-May-05 20:34
RYU^^3-May-05 20:34 
GeneralRe: a question on heap..... Pin
Bob Stanneveld3-May-05 22:19
Bob Stanneveld3-May-05 22:19 
GeneralRe: a question on heap..... Pin
RYU^^6-May-05 15:10
RYU^^6-May-05 15:10 
GeneralRe: a question on heap..... Pin
Bob Stanneveld8-May-05 1:14
Bob Stanneveld8-May-05 1:14 
GeneralRe: a question on heap..... Pin
Toby Opferman10-Jun-05 5:42
Toby Opferman10-Jun-05 5:42 
GeneralRe: a question on heap..... Pin
Bob Stanneveld10-Jun-05 9:50
Bob Stanneveld10-Jun-05 9:50 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.