Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Linker problem

bogdanul2003bogdanul2003 Member Posts: 153
I'm trying to make an application that reads data from USB and for this I need to use some header files and libraries from windows DDK.

#include
#include

void __fastcall TForm1::Button1Click(TObject *Sender)
{
GUID hidGUID;


//Get the HID GUID value - used as mask to get list of devices
HidD_GetHidGuid (&hidGUID);
}

The compiler has no problem with this but when I want to build the project the linker gives the next error:
[Linker Error] Unresolved external '__stdcall HidD_GetHidGuid(_GUID *)' referenced from E:PROIECTEUSBUNIT1.OBJ

I have included the path to DDK libraries in "Directories/Conditionals" from project settings and I have even copied some libraries in the default library directory of Borland builder (I use borland builder 5).

Can someone help me out with this?

10x

Comments

  • luckyboyluckyboy Member Posts: 105
    try the following
    Project menu -> Add to project
    make sure that the Dialog file type is *.lib and browse for your *.lib files
    this should make every thing working correctly

    Mohammad Nasim
  • bogdanul2003bogdanul2003 Member Posts: 153
    : try the following
    : Project menu -> Add to project
    : make sure that the Dialog file type is *.lib and browse for your
    : *.lib files
    : this should make every thing working correctly
    :
    : Mohammad Nasim

    10x Nasim. It seems it works but I think there is something wrong with the .lib file. Now the linker gives the next error:
    [Linker Error] 'E:WINDDK3790.1830LIBWXPI386SETUPAPI.LIB' contains invalid OMF record, type 0x21 (possibly COFF)

    Should I get another version of DDK or another version of C++ Builer ?
  • luckyboyluckyboy Member Posts: 105
    : 10x Nasim. It seems it works but I think there is something wrong
    : with the .lib file. Now the linker gives the next error:
    : [Linker Error] 'E:WINDDK3790.1830LIBWXPI386SETUPAPI.LIB'
    : contains invalid OMF record, type 0x21 (possibly COFF)
    :
    : Should I get another version of DDK or another version of C++ Builer
    : ?

    OMF, COFF are really very new conventions to me.
    as they say in our comunity
    if you said "I don't know", you have already given the right answer.
    so i don't know
Sign In or Register to comment.