From: | "Finn Kettner" <fk(at)akf(dot)dk> |
---|---|
To: | Magnus Hagander <mha(at)sollentuna(dot)net> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | RE: libpq.dll and VB |
Date: | 2000-08-25 11:58:43 |
Message-ID: | 200008251106.e7PB6Z593616@hub.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 24 Aug 00 at 16:51, Magnus Hagander wrote about RE: [HACKERS]
libpq.dll and VB:
> > Has anybody got any experience using libpq.dll from Visual Basic
> > (currently using Visual Studio 6), and if so, do you have the
> > declarations handy. I have a little trouble finding out how the PGconn
> > and PGresult should look like, and as far as I know these are required
> > to use the connect and execute functions in the library.
> > PS. If anybody know a program to automatically extract informations
> > from a dll and create a api.txt file for Visual Basic, then please let
> > me know.
> I don't know exactly which format VB expects, but you can get a list
> of exports from the DLL using: dumpbin /exports libpq.dll
Yes, I've tried that, but unfortunately, that is not exactly the
format that VB need, but I have considered using it as a starting
point.
> If you also need the function definitions, check libpq-fe.h for C
> style syntax. (It's in src/interfaces/libpq)
I need function definitions and structure (called Type in VB)
definitions, and yes I have looked in libpq-fe.h, actually this is
the placed where the dll is build :-). But as mentioned earlier, the
structures for PGconn and PGresult is not in this file (they are
typedef'ed directly from pg_conn and pg_result, which I can't find in
any of the included files, so I actually wonder how the dll is build
in the first place???).
> As a sidenote, you may be much better off using ADO with the ODBC
> driver - it's definitly move VB-friendly.
Yes, but what I forgot to tell you, is that I'm trying to create a
activex control, which is to be placed on a (intranet) web page,
using the Esker plugin, so ODBC is not the best way to go, as that
would need a ODBC-connection be set up on each client machine, which
are to use the activex control, so that's why I need to go directly
to the dll file (which can be fetched from the page). To set up an
ODBC connection you would need to install the psqlodbc.dll anyway, so
why not take the direct way.
Yours faithfully.
Finn Kettner.
From | Date | Subject | |
---|---|---|---|
Next Message | Brook Milligan | 2000-08-25 14:08:50 | advice on extensions needed |
Previous Message | Magnus Hagander | 2000-08-25 11:31:51 | RE: libpq.dll and VB |