Click here to Skip to main content
13,766,204 members

C / C++ / MFC

 
AnswerRe: Mouse Wheel scrolling support for MFC application. Pin
Jochen Arndt9-Jul-18 1:52
mvpJochen Arndt9-Jul-18 1:52 
GeneralRe: Mouse Wheel scrolling support for MFC application. Pin
Member 139038189-Jul-18 20:16
memberMember 139038189-Jul-18 20:16 
GeneralRe: Mouse Wheel scrolling support for MFC application. Pin
Victor Nijegorodov9-Jul-18 21:37
memberVictor Nijegorodov9-Jul-18 21:37 
GeneralRe: Mouse Wheel scrolling support for MFC application. Pin
Member 139038189-Jul-18 22:04
memberMember 139038189-Jul-18 22:04 
GeneralRe: Mouse Wheel scrolling support for MFC application. Pin
Jochen Arndt10-Jul-18 1:10
mvpJochen Arndt10-Jul-18 1:10 
GeneralRe: Mouse Wheel scrolling support for MFC application. Pin
Member 1390381810-Jul-18 23:50
memberMember 1390381810-Jul-18 23:50 
GeneralRe: Mouse Wheel scrolling support for MFC application. Pin
Jochen Arndt11-Jul-18 0:10
mvpJochen Arndt11-Jul-18 0:10 
QuestionObject pointer as method argument Pin
_Flaviu8-Jul-18 1:43
member_Flaviu8-Jul-18 1:43 
I have a CData derived from CObject. In my CDocument, I have a CMap, with key as int, and values as CData*.

In a CMyDocument method I have:
void CMyDocument::GetData(int nItemData, CData* pData/* = NULL*/)
{
	m_MapData.Lookup(nItemData, pData);
	TRACE("Inside doc method: pData is not NULL: %d\n", NULL != pData);
}

and in my CMyView:
int nItemData = 1;
CData* pData = NULL;
GetDocument()->GetData(nItemData, pData));
TRACE("In MyView: pData is not NULL: %d\n", NULL != pData);


and here is the result:

Inside doc method: pData is not NULL: 1
In MyView: pData is not NULL: 0

Why inside CMyDocument I have a valid pData, but outside not ?

modified 8-Jul-18 10:17am.

AnswerRe: Object pointer as method argument Pin
Richard MacCutchan8-Jul-18 8:23
protectorRichard MacCutchan8-Jul-18 8:23 
GeneralRe: Object pointer as method argument Pin
_Flaviu8-Jul-18 20:57
member_Flaviu8-Jul-18 20:57 
NewsRe: Object pointer as method argument Pin
Richard MacCutchan9-Jul-18 4:01
protectorRichard MacCutchan9-Jul-18 4:01 
AnswerRe: Object pointer as method argument Pin
CPallini8-Jul-18 21:59
mvpCPallini8-Jul-18 21:59 
GeneralRe: Object pointer as method argument Pin
_Flaviu9-Jul-18 6:45
member_Flaviu9-Jul-18 6:45 
QuestionMFC Static Library Project Pin
Richard Andrew x647-Jul-18 17:04
professionalRichard Andrew x647-Jul-18 17:04 
AnswerRe: MFC Static Library Project Pin
Victor Nijegorodov7-Jul-18 22:48
memberVictor Nijegorodov7-Jul-18 22:48 
GeneralRe: MFC Static Library Project Pin
Richard Andrew x648-Jul-18 4:26
professionalRichard Andrew x648-Jul-18 4:26 
QuestionUsing fstream with USB Serial Port Pin
OscardelaGrouch6-Jul-18 21:53
memberOscardelaGrouch6-Jul-18 21:53 
AnswerRe: Using fstream with USB Serial Port Pin
Richard MacCutchan7-Jul-18 0:25
protectorRichard MacCutchan7-Jul-18 0:25 
GeneralRe: Using fstream with USB Serial Port Pin
OscardelaGrouch7-Jul-18 7:39
memberOscardelaGrouch7-Jul-18 7:39 
GeneralRe: Using fstream with USB Serial Port Pin
Richard MacCutchan7-Jul-18 7:52
protectorRichard MacCutchan7-Jul-18 7:52 
GeneralRe: Using fstream with USB Serial Port Pin
OscardelaGrouch7-Jul-18 7:55
memberOscardelaGrouch7-Jul-18 7:55 
GeneralRe: Using fstream with USB Serial Port Pin
OscardelaGrouch7-Jul-18 9:21
memberOscardelaGrouch7-Jul-18 9:21 
GeneralRe: Using fstream with USB Serial Port Pin
speedbump997-Jul-18 13:59
memberspeedbump997-Jul-18 13:59 
GeneralRe: Using fstream with USB Serial Port Pin
OscardelaGrouch7-Jul-18 14:18
memberOscardelaGrouch7-Jul-18 14:18 
GeneralRe: Using fstream with USB Serial Port Pin
speedbump997-Jul-18 15:51
memberspeedbump997-Jul-18 15:51 

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.


Advertise | Privacy | Cookies | Terms of Service
Web01-2016 | 2.8.181114.1 | Last Updated 15 Nov 2018
Copyright © CodeProject, 1999-2018
All Rights Reserved.
Layout: fixed | fluid