Welcome to the new platform of Programmers Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use it's exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
Problem in Exporting a function from DLL
I am using Delphi5. I have made a DLL. In DLL there is a unit (with form i.e. GUI) named uExport. As you know that any form in the Delphi is itself a class. I have written a public function in this Form class.
Now I want to import the same. To do so I had written Export and stdcall at the end of function declaration and definition.
The DLL is getting built properly. I also have a stand alone EXE to test DLL.
When I use the exported function of DLL in said exe, it (exe) does not give any problem or error but at the same time it doesnot produce any result.
To know the reason I debugged the DLL code but the control does not ever enter in the exported function of form class.
At the same time the control does enter in the exported function if it is global and not in the class.
Please tell me how to export a function of any class from Delphi DLL?