Q:
Hi,I have problem to determine whether a point is a NULL point in vc++ 2005,
Here is my source code:
private: System::Void treeView1_MouseClick(System::Object^ sender, System::Windows::Forms::MouseEventArgs^ e) {
Point mouseDownLocation = Point(e->X,e->Y);
TreeNode ^newNode = treeView1->GetNodeAt(mouseDownLocation);
if(newNode == NULL )
......
}
There is error whith these code,the error message is:error C2065: 'NULL' : undeclared identifier.
Am I missing the head file? If it is ,which file?
Thanks for your help.
A:
Don't use NULL in managed code. Use nullptr.
if(newNode == nullptr)
{
. . .
}