Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. newbie question about vc++ and dlls

newbie question about vc++ and dlls

Scheduled Pinned Locked Moved C / C++ / MFC
csharpc++questionvisual-studio
5 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    charlener
    wrote on last edited by
    #1

    (in visual studio .net) I'm a programmer mostly coming from the academic end of things (UNIX, gcc, etc.) and for the life of me cannot get variable types/functions from this dll. It's a development package for eeg analysis software that's supposed to allow me to read their specialized file format in c++ programs. Here's the link to the development kit: http://www.axon.com/pub/utility/axonfsp/windows/ and I'm interested in using the axabffio32.dll functions and what (esp. things like ABF_ReadOpen and Abffileheader). I've tried linking in the dir of the dll, copying the dll to the project dir, setting everything to release and adding the dll as a resource (as well as the #include of the dll)...what am I doing wrong??? here's the code: void main( int argc, char **argv ) { ABFFileHeader FH; ABF_Initialize(); ABFH_Initialize(&FH); Acquisition( argv[1], &FH ); ABF_Cleanup(); } and here's the error I most often get: c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(16) : error C2065: 'ABFFileHeader' : undeclared identifier c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(16) : error C2146: syntax error : missing ';' before identifier 'FH' c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(16) : error C2065: 'FH' : undeclared identifier c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(18) : error C3861: 'ABF_Initialize': identifier not found, even with argument-dependent lookup c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(19) : error C3861: 'ABFH_Initialize': identifier not found, even with argument-dependent lookup

    A 1 Reply Last reply
    0
    • C charlener

      (in visual studio .net) I'm a programmer mostly coming from the academic end of things (UNIX, gcc, etc.) and for the life of me cannot get variable types/functions from this dll. It's a development package for eeg analysis software that's supposed to allow me to read their specialized file format in c++ programs. Here's the link to the development kit: http://www.axon.com/pub/utility/axonfsp/windows/ and I'm interested in using the axabffio32.dll functions and what (esp. things like ABF_ReadOpen and Abffileheader). I've tried linking in the dir of the dll, copying the dll to the project dir, setting everything to release and adding the dll as a resource (as well as the #include of the dll)...what am I doing wrong??? here's the code: void main( int argc, char **argv ) { ABFFileHeader FH; ABF_Initialize(); ABFH_Initialize(&FH); Acquisition( argv[1], &FH ); ABF_Cleanup(); } and here's the error I most often get: c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(16) : error C2065: 'ABFFileHeader' : undeclared identifier c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(16) : error C2146: syntax error : missing ';' before identifier 'FH' c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(16) : error C2065: 'FH' : undeclared identifier c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(18) : error C3861: 'ABF_Initialize': identifier not found, even with argument-dependent lookup c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\abfDLL.cpp(19) : error C3861: 'ABFH_Initialize': identifier not found, even with argument-dependent lookup

      A Offline
      A Offline
      axid3j1al
      wrote on last edited by
      #2

      You need to search for the identifier ABFFileHeader in the eeg include files and then #include it. Those errors do not relate to dlls in any way. Then once you have done that just link to the corresponding .lib for the header file.

      C 1 Reply Last reply
      0
      • A axid3j1al

        You need to search for the identifier ABFFileHeader in the eeg include files and then #include it. Those errors do not relate to dlls in any way. Then once you have done that just link to the corresponding .lib for the header file.

        C Offline
        C Offline
        charlener
        wrote on last edited by
        #3

        ummmm.... well, this, perhaps? // HEADER: ABFHEADR.H. // PURPOSE: Defines the ABFFileHeader structure, and provides prototypes for // functions implemented in ABFHEADR.CPP for reading and writing // ABFFileHeader's. tried compiling with #include "ABFHEADR.H" and here's the error I get now... Compiling... abfDLL.cpp c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\ABFHEADR.H(961) : error C2501: 'STATIC_ASSERT' : missing storage-class or type specifiers

        B A 2 Replies Last reply
        0
        • C charlener

          ummmm.... well, this, perhaps? // HEADER: ABFHEADR.H. // PURPOSE: Defines the ABFFileHeader structure, and provides prototypes for // functions implemented in ABFHEADR.CPP for reading and writing // ABFFileHeader's. tried compiling with #include "ABFHEADR.H" and here's the error I get now... Compiling... abfDLL.cpp c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\ABFHEADR.H(961) : error C2501: 'STATIC_ASSERT' : missing storage-class or type specifiers

          B Offline
          B Offline
          bilal78
          wrote on last edited by
          #4

          It might be due to some other include files, that are missing. I dont think there is any declaration like "STATIC_ASSERT" in mfc or win32, so it must be from some other 3rd party library.

          1 Reply Last reply
          0
          • C charlener

            ummmm.... well, this, perhaps? // HEADER: ABFHEADR.H. // PURPOSE: Defines the ABFFileHeader structure, and provides prototypes for // functions implemented in ABFHEADR.CPP for reading and writing // ABFFileHeader's. tried compiling with #include "ABFHEADR.H" and here's the error I get now... Compiling... abfDLL.cpp c:\Documents and Settings\administrator\My Documents\Visual Studio Projects\abfDLL\ABFHEADR.H(961) : error C2501: 'STATIC_ASSERT' : missing storage-class or type specifiers

            A Offline
            A Offline
            axid3j1al
            wrote on last edited by
            #5

            How are you trying to compile this? I just did it and it worked for me. I think that STATIC_ASSERT thing is erroneous I greped the src for it and could not find it anywhere. ANyway I put it axon* in c:\test then just open all the C:\test\AxonDev\Comp\Ax* and compile them. THe paths need to be adjusted like I had to prepend 'c:\test' to everything and change the post link setup for the .lib but thats it. Regards, Axe

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups