Solved

ActiveX problem

Posted on 2007-11-26
6
279 Views
Last Modified: 2010-04-05
Hi all,

I've posted a question about this subject some weeks ago.
See: http://www.experts-exchange.com/Programming/Languages/Pascal/Delphi/Q_22949796.html

I need to write a plug-in DLL for a software package. The company of this software package provided a code sample in Visual Basic how to work this out. Unfortunately I'm using Delphi and need to translate this to implement it in my project.

As it seems, the DLL is an ActiveX library that has got some Ole Automation objects in it. I've extracted the type library from the sample (VB) DLL and created a new Delphi project and my own Ole Automation objects based on the specifications in the sample VB type library.

So far so good.

When I start the software package my DLL is loaded, because I specified the Host Application as parameter in the Delphi IDE and it goes through the Initialization section of my code asuming my Ole objects are created. The DLL is also locked by Windows as long as the software package is loaded. However, the interface doesn't seem to work. I quite can't figure out what I'm doing wrong here.

I've opened a FTP account in which I have put some files.

VB_BPWindow ---- plug-in sample in VB code provided by the manufacturer of the software package.
Delphi_BPWindow --- My translation project so far in Delphi.
TypeLibsAndDLLs --- Resulting DLLs and Type libraries from the VB sample code and my Delphi project.

FTP login:

Server: ftp.systony.nl
User ID: DelphiCoder
Password: WU&5BsJZ

I've put 500 points on it.

Thanks in advance,

JeePeeTee


Open in new window

0
Comment
Question by:JeePeeTee
  • 3
6 Comments
 
LVL 4

Author Comment

by:JeePeeTee
ID: 20359874
Anyone?
0
 
LVL 4

Author Comment

by:JeePeeTee
ID: 20387679
Ok, no Expert comments yet.

I've figured something out and made some progress on it. The type libraries are now exactly the same in my project as it is in the VB sample DLL. It's still not working though. When I compare the two DLLs (the VB Sample DLL and my Delphi DLL) in a resource editor, and I see some differences that might cause the troubles.

See the screenshot below:
http://www.danceboost.com/vbvsdelphidll.jpg

How can I publish my classes the same way they did in my DLL?

Thanks,

JeePeeTee
0
 
LVL 4

Author Comment

by:JeePeeTee
ID: 20403290
Any experts who have any idea at all? I'm really stuck with this.
0
 
LVL 5

Accepted Solution

by:
Steven-Fernandez earned 500 total points
ID: 20762193
Are you about to call any functions from your DLL?

Also there's an issue that Delphi programmers seem to forget. Remember you use all parameters when calling the functions from the DLL in delphi.

VB will let you get away with leaving parameters out but delphi will not.

 

0
 
LVL 1

Expert Comment

by:Computer101
ID: 21216626
Forced accept.

Computer101
EE Admin
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

830 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