Solved

Simple WinInet problem

Posted on 2000-02-18
3
1,045 Views
Last Modified: 2013-11-20
I have a program [sample] from MSDN which gets a file from an internet address thru a proxy server. I am not able to link the file ...
get the following errors
r.obj : error LNK2001: unresolved external symbol __imp__InternetOpenA@20
r.obj : error LNK2001: unresolved external symbol __imp__InternetErrorDlg@20
r.obj : error LNK2001: unresolved external symbol __imp__InternetSetOptionA@16
r.obj : error LNK2001: unresolved external symbol __imp__InternetReadFile@16
r.obj : error LNK2001: unresolved external symbol __imp__InternetQueryDataAvailable@16
r.obj : error LNK2001: unresolved external symbol __imp__HttpQueryInfoA@20
r.obj : error LNK2001: unresolved external symbol __imp__InternetQueryOptionA@16
r.obj : error LNK2001: unresolved external symbol __imp__HttpSendRequestA@20
r.obj : error LNK2001: unresolved external symbol __imp__InternetOpenUrlA@24
r.obj : error LNK2001: unresolved external symbol __imp__InternetGetLastResponseInfoA@12
Debug/r.exe : fatal error LNK1120: 10 unresolved externals

I'm new to MFC programming so I don't know what the problem is.....should have to link in some other lib perhaps ???
0
Comment
Question by:bluezen
3 Comments
 
LVL 1

Accepted Solution

by:
oarguimb earned 50 total points
ID: 2534622
I think it's just a link problem.

Have you tried to add Wininet.lib to your project ? (If it fails read the help perhaps you have to add a higher level library...but try wininet.lib first)

To add this lib just go to you project settings and in the link tab just add WININET.LIB in "Object/library modules" edit box.
0
 
LVL 1

Expert Comment

by:mahno
ID: 2534624
Hi, bluezen

In "Project->Setting->General->Microsoft Foundation Classes" U select "Use MFC in a static labrary" / "Use MFC in a shared DLL"?
0
 
LVL 1

Author Comment

by:bluezen
ID: 2535987
Thanks !!!
That was a very clear answer and it solved my problem !
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
cat dog challenge 18 124
Include multiple hostnames in this command? 3 53
Separate into files by filename 12 76
Annoying "thing" blocks my view 4 83
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

27 Experts available now in Live!

Get 1:1 Help Now