NOTICE: This version of the NSF Unidata web site (archive.unidata.ucar.edu) is no longer being updated.
Current content can be found at unidata.ucar.edu.

To learn about what's going on, see About the Archive Site.

Problems with netcdf and VBasic

Dear all,

I wanted to use netcdf.dll in a visual basic program. I have followed
the instructions of a mail in this list titled Netcdf and Visual Basic 6
and I have built a test program:


   Public Declare Function nc_create Lib
"c:\windows\system32\netcdf.dll" (ByRef path As String, ByVal mode As
Long, ByVal ncidp As Long) As Long
   Public Const NC_NOCLOBBER As Long = 4

   Sub test()
        Dim status As Long
        Dim nci As Long
        Dim file As String
        file = "d:\fozj.nc"
        status = nc_create(file, NC_NOCLOBBER, nci)

   End Sub

Unfortunely, when I have executed this code, VB give me an error:  Bad
DLL Calling Convention, so I think the argumets are wrong. Could anybody
help me? Are there anybody who use VB6 and netcdf?

My netcdf version is 3.6.1 and I have donwload a precompiled dll, called
netcdf.dll

Thank you in advance,
Pedro Montero

--
Pedro Montero
_______________________


Pedro Montero Vilar
E-mail: pmontero@xxxxxxxxxxxx

Instituto Tecnolóxico para o Control do Medio Mariño (INTECMAR)
R/Peirao de Vilaxoán, S/N
CP: 36611, Vilagarcía de Arousa (Pontevedra)
Tfno.: +34 986512320/22
Fax:   +34 986512300

_________________________






  • 2005 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the netcdfgroup archives: