Using The DLL in delphi 5

The latest version of the UOAI library and all directly related information can be found in this forum.

Using The DLL in delphi 5

Postby Endless Night on Thu Sep 24, 2009 3:53 pm

This is all from Delphi 5 .. but im sure other versions will be simular.

Thiers 2 methods.
(1) Open your project - from project menu option choose "import Type Library" . Choose create option. This will create a uoai_tlb.pas file and add it to your current project.
Add UOAI_TLB to the 'USES' declaration of any forms/files you need to use the UOAI object in . Under add Var UOAI : TUOAI , under YOUR initailzation code section add UOAI := Create(Self) ; (Generally procedure TForm1.FormCreate(Sender: TObject) )

(2) Start a New Project of Type Package.
From project menu from project menu option choose "import Type Library" . Choose Install option. Finish off by installing the package. This will add 2 components under the Active X tab of the component bar. UOAI UOitemList. Add these components to any form/file you need as normal.

NOTE: In both instances make sure the "Generate Component Wrapper' check box is checked on the import type library function. (I belive this is already defaulty checked)

Of course if goes without saying that this is access to the com object without all the frills of the .Net wrapper, so some functions would need to be implemented.
Endless Night
n00b
 
Posts: 7
Joined: Sat May 02, 2009 3:53 am

Re: Using The DLL in delphi 5

Postby Artaxerxes on Thu Sep 24, 2009 5:00 pm

Great! Simpler than I thought it would be, i didn't know Delphi was able to import interfaces from a typelibrary directly!
I will eventually try this myself and collect all usage info into the documentation; also as you say some extra tool-functions to use UOAI from languages like C and Delphi might be usefull too.
Thanks for figuring that out! As long as UOAI is still lacking suitable documentation i will refer everyone trying to use UOAI from delphi to this thread.

Greetz,
Artaxerxes
Artaxerxes
Site Admin
 
Posts: 530
Joined: Tue Nov 18, 2008 9:51 pm


Return to UOAI Developers Forum

Who is online

Users browsing this forum: No registered users and 1 guest

cron