🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #14426

Re: whats the solution of this linker error ????

#14426
From: Eyyub Volkan �ektimur
Date: Wed, 13 Aug 2003 15:18
58 lines
2564 bytes
did you include the related .lib file to your project ?

if you don't have .lib file you can generate it from .dll by using "implib"

for exm:

in command prompt;

implib MyLib.LIB MyDLL.DLL

-- 
___________________________________
Eyyub Volkan �ektimur
Proya Software & Trade Inc.
Head of Core Development Department
"US Kazi" <umarkazi@hotmail.com> wrote in message
news:3f3a54d1$1@newsgroups.borland.com...
>
> I am trying to read parallel port of PC while using windows
> XP.i have got a manufacturer driver, which has got a DLL file
> to communicate with parallel port. but i am having a linker
> error which is confusing me ,and i don't know how to solve it
> the source code is below followed by the errors
>
> *************************************
> #include <stdio.h>
> #include <dos.h>
> # include "BytioXP.h" //manufacturer's provided header file//
>
> #define baseadd (0x378)
>
> extern "C"
>
> void __import __stdcall OutVal(unsigned short IOAddress, unsigned short
Value);
> short __import __stdcall InpVal(unsigned short IOAddress);
>
> {
> int x;
> OutVal(baseadd,5);
> x == InpVal(baseadd);
> cout << "the value is " << x<<;
> getch();
> return 0;
> }
>
> and the error which comes up after compiling is
>
> [Linker Error] Unresolved external 'OutVal' referenced from C:\PROGRAM
FILES\BORLAND\CBUILDER4\PROJECTS\PROJECT2.OBJ.
>
> [Linker Error] Unresolved external 'InpVal' referenced from C:\PROGRAM
FILES\BORLAND\CBUILDER4\PROJECTS\PROJECT2.OBJ.
>
> please tell me where things are going wrong.. and how can i fix them
> regards
>
>
Technical Details
Message-ID: <3f3a56e0@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!news-out.visi.com!petbe.visi.com!ash.uu.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <3f3a54d1$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 10cc67,c04482dd09229097
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-08-13 08:31:50 PST
From: "Eyyub Volkan �ektimur" <evcektimur@prokon.com.tr>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3f3a54d1$1@newsgroups.borland.com>
Subject: Re: whats the solution of this linker error ????
Date: Wed, 13 Aug 2003 18:18:48 +0300
Lines: 60
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 213.232.9.4
Message-ID: <3f3a56e0@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1060787936 213.232.9.4 (13 Aug 2003 08:18:56 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-08!supernews.com!news-out.visi.com!petbe.visi.com!ash.uu.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail