Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

Compiler Error C3808

Error Message

'type' : a class with the ComImport attribute cannot define member 'member', only abstract or dllimport functions are allowed

A type that derived from ComImportAttribute cannot define member.


The following sample generates C3808.

// C3808.cpp
// compile with: /c /clr:pure user32.lib
using namespace System::Runtime::InteropServices;

ref struct S1 {
   int f() {}   // C3808
   virtual int g() abstract;   // OK

   int printf(System::String ^, int i);   // OK
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2014 Microsoft. All rights reserved.