home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.os.os2.programmer:4469 comp.os.os2.apps:5562
- Path: sparky!uunet!vnet.ibm.com
- From: wtracey@vnet.ibm.com (Bill Tracey)
- Message-ID: <19920826.200530.323@almaden.ibm.com>
- Date: Wed, 26 Aug 92 23:04:54 EDT
- Newsgroups: comp.os.os2.programmer,comp.os.os2.apps
- Subject: Re: Exporting variables from DLL's
- Reply-To: wtracey@vnet.ibm.com
- Organization: IBM Corp.
- News-Software: UReply 3.0
- References: <1992Aug26.213514.14162@natinst.com>
- Lines: 23
-
- In <1992Aug26.213514.14162@natinst.com> Malathi Ramdas writes:
- > Is it possible to export global variables from a DLL? I have written a
- >DLL that exports 3 variables. I have created an import library for an appl
- >ication that wishes to use this DLL. As soon as I try to run this application
- >it complains about not being able to find these variables in the DLL module.
- >It seems like from the export declararions in the .def file it is assuming
- >that these are functions and not variables. Should I be doing anything differe
- >nt or is it simply impossible to export global variables? By the way, I am compi
- >ling and linking the DLL application using CSET/2 and LINK386.
- >
-
-
- This should work just fine. Is it possible the DLL was linked with
- the /noi (noignorecase) option and the calling application was linked
- without it? One common mistake that causes errors like this is for the
- case of the variable in the DLL to be different than the case of the
- variable in the calling program. If the case of the variable name in
- the error message is different from the case of the variable name in the
- DLL code then the case mismatch is probably the problem.
-
- Hope this helps,
-
- Bill Tracey
-