home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!think.com!ames!agate!usenet.ins.cwru.edu!cleveland.Freenet.Edu!ae302
- From: ae302@cleveland.Freenet.Edu (Peter Haller)
- Newsgroups: comp.os.ms-windows.programmer.misc
- Subject: Re: BORDLG class dialog boxes
- Date: 11 Nov 1992 02:29:20 GMT
- Organization: Case Western Reserve University, Cleveland, OH (USA)
- Lines: 34
- Message-ID: <1dpr60INN8pf@usenet.INS.CWRU.Edu>
- References: <josteinl.1@saga.oih.no> <10966@uqcspe.cs.uq.oz.au>
- Reply-To: ae302@cleveland.Freenet.Edu (Peter Haller)
- NNTP-Posting-Host: slc12.ins.cwru.edu
-
-
- In a previous article, josteinl@saga.oih.no (LEIRA JOSTEIN) says:
-
- >
- >You'r right. You must load the BWCC.DLL. There are two ways to do it.
- >
- >First method:
- >
- > Enter these two lines of code at the start of your program:
- >
- > HANDLE hDLL; /* This line could be defined in the app-class */
- > hDLL = LoadLibrary("BWCC.DLL"); /* and this line in the constructor */
- >
- > and this line at the end (of WinMain):
- >
- > FreeLibrary(hDLL); /* and this line in the destructor */
- >
- > Then you should link your program with BWCC.LIB and IMPORT.LIB. (The
- > Borland documentation says the linking order i important.)
- Nope, this is wrong, partially. If you link in the bcww.lib file
- you do not need to use LoadLibrary(). When you link with bwcc.lib
- you force an implicit link and link all the exported functions.
- LoadLibrary() allows you to load a DLL dynamically. When you do
- thing your way you don't do any harm, but it is redundant. Using
- LoadLibrary() by itself though will not work, unless you then
- call GetProcAddress() to retrieve the exported functions that you
- require.
-
- PCH
- --
- Peter C. Haller | 'If you do what you
- Lorain Products | have always done,
- ae302@cleveland.Freenet.Edu | expect what you have
- "Are we having fun yet?" | always received.'
-