Solved

error LNK2001 again!

Posted on 2000-04-23
5
243 Views
Last Modified: 2010-04-02
I call InetIsOffline in my program, which is declared in "Intshcut.h".
I include this header file, but when linking, error LNK2001 appears. How to resolve it? Pleas help me.
0
Comment
Question by:seuwind
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 

Expert Comment

by:kishk91
ID: 2741546
Did you linked the correct dll???]
this error is due to missing dll....
kishk
0
 
LVL 4

Expert Comment

by:AssafLavie
ID: 2742055
Make sure you link with shell32.lib.
Project settings -> Link -> Object/Library modules -> "shell32.lib".
0
 
LVL 23

Accepted Solution

by:
chensu earned 50 total points
ID: 2742278
You need to link with url.lib.

Choose the Project/Settings... menu, the Link tab, append url.lib to the Object/library modules edit box.
0
 

Author Comment

by:seuwind
ID: 2742709
Thanks,ChenSu. You helped me again.
I wonder how can I know which lib to link. It isn't said in the header file or MSDN. Can you tell me?
0
 
LVL 23

Expert Comment

by:chensu
ID: 2742838
The Internet shortcut utility functions use url.lib. InetIsOffline is one of them.

Internet shortcut utility functions

InetIsOffline
MIMEAssociationDialog
TranslateURL
URLAssociationDialog

You may also search the lib directory for "InetIsOffline".
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
Many modern programming languages support the concept of a property -- a class member that combines characteristics of both a data member and a method.  These are sometimes called "smart fields" because you can add logic that is applied automaticall…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.

734 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