Phil Middlemiss said: > that's what I thought it would be. My problem though, is that I'm > not quite sure what I should be looking for to find the correct > #pragma or declaration
I have just thought of another approach that you can take to doing this, although it may be more work that its worth: In you Delphi code do a {$L WhatEverItsCalled.OBJ} function mobileCreateConnection(var connection: THIS_CONNECTION): Integer; external; and then you can link to and call the function directly from Delphi. As far as I know Delphi dones no name mangling on external declarations, and in fact you have to add underscores if you are linking to a library that has then included. The only drawback to this is that if the library code in question calls standard C library functions that are not included in the library you have a few issues to deal with. One approach it to duplicate the library functions in Delphi as stubs that call the equivalent Delphi code (eg, for malloc and the like), the other approach would be to link in the appropiate BC++ OBJS files and create whever stubs are needed to do the name mangling, probably via some assembler code. It all depend on how the librarty code was originally written, and if its was carefully designed to facilitate other langauge linking or not. Cheers, Max. --------------------------------------------------------------------------- New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED] Website: http://www.delphi.org.nz To UnSub, send email to: [EMAIL PROTECTED] with body of "unsubscribe delphi" Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/