title: C++/CLI: linker gives "unresolved token" for win32 function
body: <p>Folks,</p>
  
  <p>I just created my first C++/CLI project (Visual Studio 2008), it's a Library to allow my C# app access an point of sale tally printer.</p>
  
  <p>My library builds well and trivial functions work when called from a C# exe.</p>
  
  <p>However as soon as I include a WinGDI call (<a href="http://msdn.microsoft.com/en-us/library/dd183539(VS.85).aspx" rel="nofollow noreferrer">DeleteObject</a> in this case), the linker complains with “unresolved token” errors.</p>
  
  <blockquote>
    <p>Error 2   error LNK2028: unresolved
    token (0A000088) "extern "C" int
    __stdcall DeleteObject(void *)" (?DeleteObject@@$$J14YGHPAX@Z)
    referenced in function "private:
    __clrcall ReceiptPrinter::Epson::~Epson(void)"
    (??1Epson@ReceiptPrinter@@$$FA$AAM@XZ)    ReceiptPrinter.obj  ReceiptPrinter</p>
  </blockquote>
  
  <p>I haven't done any serious C++ in the last 4 years, and I have precious little experience of MS C++ compilers, as such I don’t know what I’m looking for in the linker settings.</p>
  
  <p>Any help will be greatfully received.</p>
  
  <p>Thanks</p>