Tuesday, August 23, 2011

Custom attributes are not consistent!

error LNK2022: metadata operation failed (80131195) : Custom attributes are not consistent: (0x0c00007d).
This is caused by specifying a managed attribute on the implementation of a C++/CLI function (i.e .cpp file), but not on the definition (i.e .h file).

Change your code so just the header file contains the attribute.

1 comment:

Anonymous said...

Thanks. This solved my error