Click here to Skip to main content
15,921,941 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Why there would be a single line left on the screen when the dialog disapear? Pin
kcynic5-Sep-07 14:28
kcynic5-Sep-07 14:28 
QuestionHow to get Serial Number of Motherboard Pin
nps_ltv3-Sep-07 23:56
nps_ltv3-Sep-07 23:56 
AnswerRe: How to get Serial Number of Motherboard Pin
chandu0044-Sep-07 0:16
chandu0044-Sep-07 0:16 
GeneralRe: How to get Serial Number of Motherboard Pin
nps_ltv4-Sep-07 1:11
nps_ltv4-Sep-07 1:11 
GeneralRe: How to get Serial Number of Motherboard Pin
chandu0044-Sep-07 2:23
chandu0044-Sep-07 2:23 
AnswerRe: How to get Serial Number of Motherboard Pin
Naveen4-Sep-07 1:40
Naveen4-Sep-07 1:40 
AnswerRe: How to get Serial Number of Motherboard Pin
Hamid_RT4-Sep-07 1:59
Hamid_RT4-Sep-07 1:59 
Questionpop up menu Pin
Wamuti3-Sep-07 23:47
Wamuti3-Sep-07 23:47 
Hi Guyz.
I am using a code snippet but something seems to be wrong with it. It is supposed to create a pop up menu from drop down menus which have already created but though it compiles successfully with the warnings:

C:\Program Files\Microsoft Visual Studio\MyProjects\Menus\MenusDlg.cpp(212) : warning C4552: '>>' : operator has no effect; expected operator with side-effect
C:\Program Files\Microsoft Visual Studio\MyProjects\Menus\MenusDlg.cpp(214) : warning C4700: local variable 'm_lMenu' used without having been initialized


i keep on getting an application error about memory referencing as if im having a memory overflow.
Below is the code snippet
void CMenusDlg::OnContextMenu(CWnd* pWnd, CPoint point)
{
// TODO: Add your message handler code here

// Declare local variables
CMenu *m_lMenu; // A pointer to the menu
CPoint m_pPoint; // A copy of the mouse position

// Copy the mouse position to a local variable
m_pPoint = point;
// Convert the position to a screen position
ClientToScreen(&m_pPoint);
// Get a pointer to the window menu

m_lMenu - GetMenu(); //(Most likely the cause of Problems)
// Get a pointer to the first submenu
m_lMenu = m_lMenu->GetSubMenu(0);
// Show the Popup Menu
m_lMenu->TrackPopupMenu(TPM_CENTERALIGN + TPM_LEFTBUTTON,
m_pPoint.x, m_pPoint.y, this, NULL);

}

Please Help. Thanks.


Man can be an Island but Islands to need water around them to be islands (Own).
AnswerRe: pop up menu Pin
Naveen4-Sep-07 0:06
Naveen4-Sep-07 0:06 
GeneralRe: pop up menu Pin
Wamuti4-Sep-07 1:43
Wamuti4-Sep-07 1:43 
Questioni decleared in .h file but even i get the exception Pin
bhogavalli suresh3-Sep-07 23:10
bhogavalli suresh3-Sep-07 23:10 
AnswerRe: i decleared in .h file but even i get the exception Pin
chandu0043-Sep-07 23:20
chandu0043-Sep-07 23:20 
AnswerRe: i decleared in .h file but even i get the exception Pin
GDavy3-Sep-07 23:26
GDavy3-Sep-07 23:26 
QuestionSQLExecDirect Function Pin
Programm3r3-Sep-07 23:06
Programm3r3-Sep-07 23:06 
AnswerRe: SQLExecDirect Function Pin
Roger Broomfield3-Sep-07 23:37
Roger Broomfield3-Sep-07 23:37 
GeneralRe: SQLExecDirect Function Pin
Programm3r3-Sep-07 23:44
Programm3r3-Sep-07 23:44 
QuestionUnresloved External symbols [modified] Pin
bhogavalli suresh3-Sep-07 23:01
bhogavalli suresh3-Sep-07 23:01 
AnswerRe: Unresloved External symbols Pin
chandu0043-Sep-07 23:05
chandu0043-Sep-07 23:05 
GeneralRe: Unresloved External symbols Pin
Cedric Moonen3-Sep-07 23:28
Cedric Moonen3-Sep-07 23:28 
AnswerRe: Unresloved External symbols Pin
Naveen3-Sep-07 23:31
Naveen3-Sep-07 23:31 
AnswerRe: Unresloved External symbols Pin
chandu0043-Sep-07 23:33
chandu0043-Sep-07 23:33 
QuestionMMIOERR_OUTOFMEMORY in debug mode Pin
rp_suman3-Sep-07 22:48
rp_suman3-Sep-07 22:48 
AnswerRe: MMIOERR_OUTOFMEMORY in debug mode Pin
Russell'4-Sep-07 0:30
Russell'4-Sep-07 0:30 
GeneralRe: MMIOERR_OUTOFMEMORY in debug mode Pin
rp_suman13-Sep-07 22:24
rp_suman13-Sep-07 22:24 
GeneralRe: MMIOERR_OUTOFMEMORY in debug mode Pin
Russell'13-Sep-07 22:34
Russell'13-Sep-07 22:34 

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.