Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
A procedure is declared with the DllImportAttribute, but either the procedure is generic or it is contained in a generic class or structure.
The common language runtime (CLR) recognizes this attribute and its EntryPoint property as designating a replacement procedure defined in an unmanaged dynamic-link library (DLL) outside the .NET Framework. When code calls the procedure to which the DllImportAttribute is applied, the common language runtime calls the designated unmanaged procedure instead.
Because unmanaged platforms outside the .NET Framework do not recognize generic types, you cannot interoperate with them using generic types.
Error ID: BC31526
To correct this error
If neither the procedure nor its container needs to be generic, then remove the Of clauses so that they are not generic.
If the procedure or its container needs to be generic, then remove the DllImportAttribute from the declaration of this procedure.