ID: Q108680
2.50b MACINTOSH kbinterop
The information in this article applies to:
All library files compiled with the Macintosh Programmer's Workshop (MPW) compiler must include an example file.
The source code for the library file has an extension of .C. The example file must have the same name as the source code file with the extension changed to .EXP. For example, if the source code is named TEST.C, the example file would be named TEST.EXP.
The following is a description of each section in an example file:
1. The first section contains introductory comments, which are optional and
can be excluded. Comments are delimited with /* and */.
/*
File: MyLibrary.exp
Contains: Exports file for the Library function set.
Copyright: (c) 1993 by John Doe, all rights reserved.
*/
2. The second section declares the library. Each .MLB file in the System
Folder:Extensions subfolder must have a unique library name. If library
names are not unique, FoxPro will generate an error stating that the
library file cannot be found. In the example below, the library name is
MyLibrary. The only text that should be changed is the library name,
which follows Fox$ on the line beginning with id =.
Library
{
id = "Fox$MyLibrary";
version = 1.3b6;
flags = system7;
heap = application, hold;
};
3. The next section declares the exported library function set that FoxPro
recognizes. Enter a valid filename following "API$" on the line
beginning "id = ". The filename must be in all uppercase (as shown in
the example below).
FunctionSet Testlib
{
id = "Fox:API$MYLIBRARY.MLB, 1.3";
version = 1.0...1.3b6;
exports = extern pascal DispatchAPI;
};
*** End Of File
When the source code file is compiled, it should be given the same name as
stated in the FunctionSet. In this example, the compiled file would be
named MYLIBRARY.MLB.
During installation, a sample .EXP file is copied onto the hard drive. The filename is TEST.EXP and it is located in the Examples subfolder of the FoxLCK folder.
Additional reference words: FoxMac 2.50b LCK KBCategory: kbinterop KBSubcategory:
Keywords : kbcode kbinterop
Version : 2.50b
Platform : MACINTOSH
Last Reviewed: May 21, 1998