Thread: LNK2019 linker error with a Windows Driver Kit API function

  1. #1
    Registered User
    Join Date
    Jul 2004
    Posts
    222

    LNK2019 linker error with a Windows Driver Kit API function

    Goal: to be able to build a cpp file with a CommonPropertySheetUIW function call properly on a Windows virtual printer driver

    Problem: I'm getting the following error message in the latest build of Microsoft Windows DDK build utility:

    Code:
    4>uicore.obj : error LNK2019: unresolved external symbol _CommonPropertySheetUIW@16 referenced in function _DrvDocumentPropertySheets@8
    4>c:\pdftron_vprint\pdfprinterdriver_v1.6\src\ui\objchk_wxp_x86\i386\pdfprinter_ui.dll : fatal error LNK1120: 1 unresolved externals
    The problem with the function CommonPropertySheetUIW (http://msdn.microsoft.com/en-us/library/ms800925.aspx) is that it's included in comptsui.h, which I've included, and one of its parameters is a callback that is defined in a different cpp file than the one the build system is complaining about. Could it be b/c I'm not configuring the makefile settings properly as I found a few links on the internet that says the project settings being inappropriate causing some functions not being able to link properly. I'm trying to adapt the DDK's CPSUISAM example onto my trunk version of printer driver if it helps.

  2. #2
    Registered User
    Join Date
    Jul 2004
    Posts
    222
    Sorry for wasting valuable space on the forum. I actually found out the reason being missing a critical library file to be included in the build system. I'm not getting any more compiler complaints now at least.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Contest Results - May 27, 2002
    By ygfperson in forum A Brief History of Cprogramming.com
    Replies: 18
    Last Post: 06-18-2002, 01:27 PM
  2. Interface Question
    By smog890 in forum C Programming
    Replies: 11
    Last Post: 06-03-2002, 05:06 PM
  3. Registery with api?
    By ismael86 in forum Windows Programming
    Replies: 1
    Last Post: 05-14-2002, 10:28 AM
  4. I need help with passing pointers in function calls
    By vien_mti in forum C Programming
    Replies: 3
    Last Post: 04-24-2002, 10:00 AM
  5. qt help
    By Unregistered in forum Linux Programming
    Replies: 1
    Last Post: 04-20-2002, 09:51 AM