Event remove method '{0}' has a parameter of type '{1}'. Windows Runtime events must have a System.Runtime.InteropServic ...

Event remove method '{0}' has a parameter of type '{1}'.  Windows Runtime events must have a System.Runtime.InteropServices.WindowsRuntime.EventRegistrationToken parameter value. Was the module being exported compiled as a winmdmodule (/target:winmdobj) for Windows Metadata export?