From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,e68e37dea4572ced X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-01-12 08:23:02 PST Path: archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.media.kyoto-u.ac.jp!newsfeed.icl.net!newsfeed.fjserv.net!proxad.net!newsfeed.tpinternet.pl!atlantis.news.tpi.pl!news.tpi.pl!not-for-mail From: Szymon Guz Newsgroups: comp.lang.ada Subject: Re: LoadLibrary problem Date: Mon, 12 Jan 2004 17:20:15 +0100 Organization: tp.internet - http://www.tpi.pl/ Message-ID: References: NNTP-Posting-Host: hal.skynet.org.pl Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Trace: atlantis.news.tpi.pl 1073924600 16491 195.116.185.50 (12 Jan 2004 16:23:20 GMT) X-Complaints-To: usenet@tpi.pl NNTP-Posting-Date: Mon, 12 Jan 2004 16:23:20 +0000 (UTC) User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.4.1) Gecko/20031008 X-Accept-Language: pl, en-us, en In-Reply-To: Xref: archiver1.google.com comp.lang.ada:4353 Date: 2004-01-12T17:20:15+01:00 List-Id: David C. Hoos wrote: > The mistake is that you need to tell the linker where to find the file > that contains the "LoadLibrary" object code. > > If you use the Win32ada library, it's found in libole32.a. > > What's more, instead of writing your own interface, you can use > the imports provided in the win32-winbase.ads file, viz.: > > pragma Import(Stdcall, LoadLibraryA, "LoadLibraryA"); -- > winbase.h:3619 > pragma Import(Stdcall, LoadLibraryW, "LoadLibraryW"); -- > winbase.h:3625 > pragma Import(Stdcall, LoadLibraryExA, "LoadLibraryExA"); -- > winbase.h:3637 > pragma Import(Stdcall, LoadLibraryExW, "LoadLibraryExW"); -- > winbase.h:3645 > > Also, note that the C calling convention is not the proper convention for > use with > Win32 libraries. > > I hope this helps > yea, that helped a lot tnx