I have a question about calling DLL's from VB using PB/DLL.
Note: I do not understand this fully, so cut me a little slack, please.
From a VB program, I want to call functions in a DLL written in C that was compiled using the stdCall method.
If interested info on the DLL is at: http://gdal.velocet.ca/projects/shapelib/index.html
I know VB only allows you to call DLL's that were compiled using the Pascal calling convention.
I have also read that PB/DLL allows you to call either type.
Could a simple PB/DLL DLL be written that could be called by VB, that in turn would call the C DLL, so that
a VB program could use the C DLL? I am thinking that this would only be about three lines per function that you want to use.
I know the best way would be to just write the application in PB/DLL to start with... But could this be done?
This would be very handy for me in some situations.
Thanks,
Tom
Note: I do not understand this fully, so cut me a little slack, please.
From a VB program, I want to call functions in a DLL written in C that was compiled using the stdCall method.
If interested info on the DLL is at: http://gdal.velocet.ca/projects/shapelib/index.html
I know VB only allows you to call DLL's that were compiled using the Pascal calling convention.
I have also read that PB/DLL allows you to call either type.
Could a simple PB/DLL DLL be written that could be called by VB, that in turn would call the C DLL, so that
a VB program could use the C DLL? I am thinking that this would only be about three lines per function that you want to use.
I know the best way would be to just write the application in PB/DLL to start with... But could this be done?
This would be very handy for me in some situations.
Thanks,
Tom
Comment