Delphi
Interface (Full Version)
Setting Up Delphi
The Delphi interface is in the runtime/delphi subdirectory. Before you can run
this program, you must set-up the Amzi! Logic Server.
You can do this by
either:
- Put the knowledgewright4/workshop directory on your PATH environment
variable
or
- Copy amzi.cfg, amzi.dll, aosutils.lsx, aodbc.lsx to
the directory containing the Delphi code.
Then you need to:
- Copy the jig reasoning engine (.xpl) file from the workshop/jigs subdirectory.
For the basic jig, this is basic.xpl, for the support jig, this is support.xpl,
etc.
- Copy the knowledgebase (.kb) file you want to run to the directory
containing the Delphi code.
This will
let you run the sample as provided. In order to write your own Delphi programs,
you need to install the Amzi! Logic Server Component. The Logic Server Component,
TLSEngine, is implemented in the Object Pascal unit amzi.pas for 32-bit Delphi.
You can use it as an Object Pascal unit by simply including a reference to it
in the USES section of your application, or you can install it in the Delphi component
library.
It is important to follow the directions carefully when installing
amzi.pas as a Delphi component. Delphi must be able to find both amzi.pas and
amzi.dll. The directions assume that you set your environment variable PATH to
include knowledgewright4\workshop. Replace N in the directions with the version
of Delphi you are using.
- Open Delphi.
- Select from the menu
'Component/Install Component�'
- Select the 'Into existing package' tab
which will by default install into the "Borland User Components" package in the
file \borland\delphiN\Lib\dclusrN0.dpk.
- Press the button marked 'Browse'
next to the 'Unit file name' box.
- Select \knowledgewright4\runtime\delphi\amzi.pas
- Note the search path should now include \knowledgewright4\runtime\delphi.
- Select 'OK' on the Install Component dialog box.
- Select 'Yes'
on the 'Package dclusrN0.dpk will be rebuilt' confirmation box.
- Select
'OK' on the dialog box informing you that TLSEngine has been added to the package.
- You should now see the Amzi! flying squirrel logo in the Additional components.
Note: When embedding KW in Delphi, make sure your jig (.xpl filename)
is different from your Delphi .exe file. This is necessary so that KnowledgeWright
does not try to use Delphi's .cfg file and vice versa.
Copyright ©1996-2002 Amzi! inc. All Rights Reserved. Amzi!,
KnowledgeWright and WebLS are registered trademarks and Subscription Plus and
Logic Server are trademarks of Amzi! inc.