InterlockedAdd64 can’t be found after adding _AFXDLL macro and clr support

  afx, c++, clr, mfc

I added _AFXDLL macro and got the following two errors:

error C2039: 'InterlockedAdd64': is not a member of '`global namespace''
error C3861: 'InterlockedAdd64': identifier not found

What is the reason and how to work around the issue?

I ran into the issue while trying to add c++/clr support for DLL which uses MFC.

Source: Windows Questions C++

LEAVE A COMMENT