| | |
A MFC linker error
Please support our ASP.NET advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Feb 2006
Posts: 1
Reputation:
Solved Threads: 0
Hi all,
I added Redo to the MenuBar of a MFC application and added the corresponding variables and functions to the CMainFrame class. The added lines to the message map is like this:
CPP / C++ / C Code:
After adding these lines, a linker error occured saying
" error LNK2001: unresolved external symbol "public: void __thiscall CMainFrame::OnEditRedo(void)" (?OnEditRedo@CMainFrame@@QAEXXZ)".
Also the added variables in the CMainFrame class are :
CPP / C++ / C Code:
afx_msg void OnEditUndo();
afx_msg void OnUpdateEditUndo(CCmdUI *pCmdUI);
afx_msg void OnEditRedo();
afx_msg void OnUpdateEditRedo(CCmdUI *pCmdUI);
The implementations of the functions OnEditUndo, OnEditUpdateUndo, OnEditRedo and OnEditUpdateRedo are empty. It is like:
void CMainFrame::OnEditRedo()
{
}
What can be the reason of the linker error after the additions to the message map.
Thanks.
I added Redo to the MenuBar of a MFC application and added the corresponding variables and functions to the CMainFrame class. The added lines to the message map is like this:
CPP / C++ / C Code:
ASP.NET Syntax (Toggle Plain Text)
ON_COMMAND(ID_EDIT_UNDO, OnEditUndo)
" error LNK2001: unresolved external symbol "public: void __thiscall CMainFrame::OnEditRedo(void)" (?OnEditRedo@CMainFrame@@QAEXXZ)".
Also the added variables in the CMainFrame class are :
CPP / C++ / C Code:
afx_msg void OnEditUndo();
afx_msg void OnUpdateEditUndo(CCmdUI *pCmdUI);
afx_msg void OnEditRedo();
afx_msg void OnUpdateEditRedo(CCmdUI *pCmdUI);
The implementations of the functions OnEditUndo, OnEditUpdateUndo, OnEditRedo and OnEditUpdateRedo are empty. It is like:
void CMainFrame::OnEditRedo()
{
}
What can be the reason of the linker error after the additions to the message map.
Thanks.
![]() |
Similar Threads
- Linker Error (C++)
- [Linker error] undefined reference to `CQTMovieFile::CQTMovieFile()' (C++)
- newmat linker error (C++)
- What is it meaned [Linker error] undefined reference to `MAPILogon@24' (C++)
- Dev-C++, GLUI linker error, undefined reference (C++)
- Linker Error>Undefined reference error to xyz (C++)
- Linker Error when program is run (Urgent help required Please") (C++)
Other Threads in the ASP.NET Forum
- Previous Thread: change the browser controls text
- Next Thread: Custom Web Server Control That Validate Itself
| Thread Tools | Search this Thread |
.net 2.0 3.5 activexcontrol advice ajax alltypeofvideos asp asp.net bc30451 bottomasp.net browser businesslogiclayer button c# c#gridviewcolumn checkbox class click commonfunctions compatible confirmationcodegeneration content contenttype control countryselector courier css database datagrid datagridview datagridviewcheckbox datalist deadlock deployment development dgv dropdownlist dropdownmenu dynamic edit embeddingactivexcontrol expose findcontrol flash flv formatdecimal forms formview gridview homeedition iframe iis javascript jquery list login menu microsoft mono mssql multistepregistration nameisnotdeclared numerical objects order panelmasterpagebuttoncontrols problem ratings rotatepage save schoolproject search security serializesmo.table silverlight smartcard sql sqlserver2005 ssl suse textbox tracking unauthorized validation vb.net video virtualdirectory vista visual-studio visualstudio vs2008 web webarchitecture webdevelopemnt webdevelopment webservice wizard xml youareanotmemberofthedebuggerusers





