tags:

views:

232

answers:

5

Hey Folks, I need to create a plug-in that updates an application. Look, I have a host application, but probably I will update it with more functions. I am working in Windows with Delphi 7. Basically, "my plugin" should add 2 or 3 new functions to the host application. How can I program a plug-in that inserts new code (new functions) in the host application without re-compiling it??

Note: I am sorry about my English. My natural language is Spanish.

Thanks anymore, Yulien.

+1  A: 

There are a number of Delphi Plugin Frameworks, commercial as well as open source. There's definitely something there that suits your needs (and budget).

fvu
+4  A: 

One method which works quite well is to create COM objects for your plugins. The advantage of this approach is that plugins can be developed in other languages other than Delphi (although com development in Delphi is by far the easiest than any other language). COM plugins will not need to be recompiled to match the current version of your host application unless your plugin interface changes.

I have implemented a successful COM based plugin architecture in a commercial product and have several plugins developed in Delphi 5 which have not needed to be recompiled at all. They still just run, even though my application is now compiled against Delphi 2007/2009.

skamradt
+1  A: 

For my plugin-based work, I use the JvPlugin framework in the JVCL. In the JVCL install, in the \examples\JvPlugin folder, you can find several examples showing how to add new features into the app, including adding new menu items into a form's menu bar.

Mason Wheeler
+1  A: 

Hello.
Here you can find an article that explain how to make an application with plugins. You must use dynamic packages and RTTI.

It include the code of a first prototype.

Regards and excuse for my bad english too. P.D: The article is in spanish.

Neftalí
Gracias hermano. Agradecido.
Yulien
+1 Buen articulo Neftali. ;)
RRUZ
Espero en breve añadir la segunda parte que está ya casi concluída.Un saludo.
Neftalí
A: 

Personally i use Hydra from Remobjects. I allows me to mix native and .NET plugins.

ErvinS