Solved

Dll C function call in Delphi.

Posted on 2002-07-26
3
162 Views
Last Modified: 2010-04-04
I have a function written in c and exported in a dll made by microsoft visual C++ 6.0 like this:

#define BIPSRESLV_API __declspec(dllexport)

BIPSRESLV_API int bips_resolve_once
          ( char * ldapHost     /* The Ldap server host name */
          , const char * node     /*The bitbus node name to be searched for */
          , char * cn          /*Returns the real cn found in the database (useful when using wildcards)*/
          , char * bipsHost     /*Returns the bips server host name */
          , int * bipsPort     /*Returns the bips server port number */
          , uint8_t * nodeAddress     /*Returns the bitbus node address (0-254) */
          );

How can I call this function from Delphi 6?
0
Comment
Question by:barzangy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 11

Accepted Solution

by:
robert_marquardt earned 500 total points
ID: 7179702
function bips_resolve_once
         (ldapHost: PChar;     // The Ldap server host name
          node: PChar;         // The bitbus node name to be searched for
          cn: PChar;           // Returns the real cn found in the database (useful when using wildcards)
          bipsHost: PChar;     // Returns the bips server host name
          var bipsPort: Integer;     // Returns the bips server port number
          var nodeAddress: Byte     // Returns the bitbus node address (0-254)
         ): Integer; stdccall;

implementation

function bips_resolve_once; external 'DLLName.DLL' name 'bips_resolve_once';
0
 
LVL 11

Expert Comment

by:robert_marquardt
ID: 7179704
Oops, stdcall not stdccall. A typo.
0
 

Expert Comment

by:CleanupPing
ID: 9342990
barzangy:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question