Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I'm trying to write an expert system for my coursework and it needs to have both a pretty user interface and a good reasoning engine, so I want to combine VB and Prolog - I can't find out how to do so anywhere - any ideas?

Other than compiling a Windows DLL in prolog, and writing Declares in VB to access it (if it can even be done), I know of no straightforward way. VB is really a wrapper around C++ when compiled (it uses C2.exe and Link.exe right from Visual C++), so think C++ combined with prolog.
I don't know about prolog compilers, but my suspicion is that the calling convention is not __stdcall (pascal), as VB expects with Win32 API stuff. Thus, you'd have to write your prolog DLL according to COM standards, then create a typelib for it, so VB can communicate with it. Don't even think about getting VB5/6 to do something other than COM.

Hey man:
Try using Amzi! Prolog. The site is www.amzi.com. They provide their own logic server in the form of a dll called amzi.dll which you will have to install in your system directory. Once this is done, you can use the zillion functions provided in the dll in the classical API style. Very simple and very very efficient. Happy programming!!

Thanks for the useful info.
For anyone else also having this problem my research has also turned up VisualProlog - which can create dlls.
http://www.pdc.dk/vip/
I dunno which i'm going to use yet - any feed back on bad experience?

![]() |
how to call a batch file ...
|
VB
|

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |