Solved

error LNK2001 again!

Posted on 2000-04-23
5
230 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
5 Comments
 

Expert Comment

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

Expert Comment

by:AssafLavie
Comment Utility
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
Comment Utility
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
Comment Utility
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
Comment Utility
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

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

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…
Written by John Humphreys C++ Threading and the POSIX Library This article will cover the basic information that you need to know in order to make use of the POSIX threading library available for C and C++ on UNIX and most Linux systems.   [s…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.

763 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

7 Experts available now in Live!

Get 1:1 Help Now