CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 1 of 1
  1. #1
    Join Date
    Jul 2009
    Posts
    1

    Delphi pass a record type to a C++ DLL

    Dear CodeGuru,

    I wrote 2 projects to test the capabilities between Delphi 2006 and Borland C++ Builder 2006.

    My delphi application callback a dll function passing 3 parameters: two integer numbers (only for test a sample sum) and a record type. The record type have 3 basic data types (integer and char) and an another array of record with two other basic data types.

    The dll application receive the pointer of a struct (declared as the same form on delphi application) and put data on the struct.

    When delphi application receive results the first part of structure, that have a sample data types, is OK (the data charged on dll is fine) but the rest of data in the array of struct are wrong, a trash is presented in the place of the data.

    What is wrong.


    Both sample code (delphi and C++) are attached in this thread.

    Thanks.
    Attached Files Attached Files

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured