The keyword is C/C++ pointer arithmetic.
The first parameter of the
AfxMessageBox()
function is an
LPCTSTR
string pointer. You are passing the address of a constant string and adds the value "5" (
myNode.m_Identifiant_Noeud
is as primary key probably some kind of
int
). So the message box shows the string starting at the 6th character (zero based 5th).
You can't concatenate strings with the
+
operator in C/C++.
You have to create a formatted string and show that:
CString strMsg;
strMsg.Format(_T("myNode: %d"), myNode.m_Identifiant_Noeud);
AfxMessageBox(strMsg.GetString());