Menu

Nodave on VB

Help
Francesco
2005-03-16
2013-05-09
  • Francesco

    Francesco - 2005-03-16

    Is possible use LibNodave in VB6 ??

     
    • Thomas Hergenhahn

      This is surely possible the same way you use other external routines located within a dll. It will be necessary to declare structeres and functions for the use with VB. As I have no VB, someone else should do that and give the code back to the project.

       
      • mctwoinch

        mctwoinch - 2005-03-25

        I am trying to use the DLL under VB.NET. It seems to be very not very easy due to the number of different structures used in the DLL. For me it seems to be possible to work with VB but by adding some new functions in the DLL which are much more easier to call from VB code.

        I confirme what lettoz said. In VB you have to declare every structures and function located in the DLL. For exemple:

        DECLARE FUNCTION setPort(byval port() as char, byval baud as char,byval parity as char) as integer

         
        • mctwoinch

          mctwoinch - 2005-03-25

          Declare Function setPort Lib "libnodave" (byval port() as char, byval baud as char,byval parity as char) as integer

           
    • Thomas Hergenhahn

      >I am trying to use the DLL under VB.NET. It seems to be very
      >not very easy due to the number of different structures used
      > in the DLL.
      You can in fact leave away parts of daveInterface in your declaration, namely those pointers to functions. This is because:
      a) your application doesn't need to access them
      b) the memory for the structure is allocated from within the dll. So your application doesn't need to know the actual size of it.
      But beware: If you try to free the memory (don't know how thi is done in VB), it may fail.
      > For me it seems to be possible to work with VB but by
      > adding some new functions in the DLL which are much more >easier to call from VB code. 
      What functions?

       

       

Anonymous
Anonymous

Add attachments
Cancel