c++ - Call dll - pcshll32.dll using delphi -


I need to use the hllapi function of pcshll32.dll Delphi. It works with IBM's personal communication, how can I change the code of Delphi? Thanks !!!

The EHLLAPI entry point (hllapi) is always called with the following four criteria:

  1. EHLLPI function number (input)
  2. Data buffer ( Input / output)
  3. buffer length (input / output)
  4. the presentation position state (input); Return code (output)

The prototype for the IBM Standard EHLPPI is: [Long HLPI (LPD, LPTR, LPDord, LPW); The prototype for IBM-enhanced EHLPPI is: [Long Helipi (LPINT, LPTR, LPIANT, LPINT);

Not every parameter has been passed by reference to the price. Thus, the function call should be an indicator for each parameter value, not the same value. For example, the following EHLLAPI query session is a perfect example of calling the session state:

  #include "hapi_c.h" straight HLDQuerySessionStatus QueryData; Int Funk, Lane, RC; Long rc; MEMAX (query data, 0, size (query data); // Init Buffer QueryData.qsst_shortname = © A ©; // session to query function = HA_QUERY_SESSION_STATUS; // Function Number Lane = Size (QueryData); Buffer RC = 0; // Input HLP (& amp; Funk; (Four *) & QueryData, & Lane; & amp; RC;) Unused; // call EHLLAPI (RC! = 0) {// check return code // ... error handling}  

All parameters of the hllapi call are pointers and return codes are EHLLPi function 4 The value of the re parameter is returned, not the value of the function.

You first need to convert hpi_c.h to Delphi (if you have not done it before To start reading here:


Comments

Popular posts from this blog

oracle - The fastest way to check if some records in a database table? -

php - multilevel menu with multilevel array -

jQuery UI: Datepicker month format -