LINK Help (linkx.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
IMPORTS Statement
 Example                                   Up Contents Index Back
─────IMPORTS Statement──────────────────────────────────────────────────────
 
     Syntax:  IMPORTS
                importdefinitions
 
     This statement defines the names and locations of functions and
     data items to be imported (usually from a DLL) for use in the
     application or DLL. A definition is required for each function or
     data item being imported.
 
     IMPORTS is an alternative to resolving references through an
     import library created by the IMPLIB utility. Functions and data
     items in an import library do not require an IMPORTS definition.
     See: IMPLIB
          Import Libraries
 
     The IMPORTS keyword marks the beginning of the import definitions,
     each on its own line. IMPORTS must appear once before the first
     definition (on the same or preceding line) and can be repeated
     before each additional definition. IMPORTS statements can appear
     more than once in the file.
 
     Import-Definition Syntax
 
     [internalname=]modulename.entry
 
     <internalname>   The function or data-item name as it is used in
                      the importing application or DLL. The default is
                      <entry>. An <internalname> is required if <entry>
                      is an ordinal value.
 
     <modulename>     The filename of the exporting application or DLL
                      that contains the function or data item.
 
     <entry>          The name or ordinal value of the function or data
                      item as defined in the <modulename> program.
                      Ordinal values are set in an EXPORTS statement.
                      See: EXPORTS Statement
 
     Internal and External Names
 
     A given symbol (function or data item) has a name for each of
     three different contexts in two programs (applications or DLLs):
 
        ■ Within the exporting program
 
        ■ As an entry point between programs
 
        ■ Within the importing program where the symbol is used
 
     If neither program uses an internal name, the symbol has the same
     name in all three contexts. If either of the programs uses an
     internal name, the symbol may have more than one distinct name.
                                    -♦-