[Date Index] [Thread Index] [Author Index]
David Konerding wrote: > > Hi, folks. I have downloaded what I believe to be the latest MathLink > SDK from Wolfram Research. I've been able to compile and run the first > test program, addtwo, but it doesn't seem to work. > > The release notes I got with the SDK are for Win 3.1, I'm using Win95 > with Visual C++ 5.0 If the stuff you got is documented for Windows 3.1, it sounds like you got the 2.2 MathLink developer's kit. You should be aware that there's a more recent version (the 3.0 MathLink developer's kit) with much better documentation and support for 32-bit Windows development. > To compile addtwo, I ran mprep to generate addtwotm.c, then created a > Vis C++ project containing addtwo.c, addtwotm.c, and the necessary > mathlink libs. > > I've copied the appropriate DLLs into the WINDOWS\SYSTEM directory. Assuming that my guess about you're getting the 2.2 developer's kit is correct, there's more that needs to be done. The .mll files also need to be copied into the WINDOWS\SYSTEM directory, and you need to create a file called MATHLINK.INI in the WINDOWS directory that reads as follows: [MathLinkProtocols] Protocol0=MLLCL` Protocol1=MLTCP` (note that's a backward apostrophe, not a normal apostrophe) Without the MATHLINK.INI file, 2.2 MathLink is unable to locate the underlying communications protocols it uses (3.0 MathLink, on the other hand, does not require this file). John Fultz email@example.com Front End Group Wolfram Research, Inc.