Solved

Link Problem

Posted on 2006-11-04
7
853 Views
Last Modified: 2007-12-19
What library file do I need to add?


BandToolBarCtrl.obj : error LNK2001: unresolved external symbol _IID_IHTMLWindow3
BandToolBarCtrl.obj : error LNK2001: unresolved external symbol _IID_IHTMLDocument3
ScriptedFrame.obj : error LNK2001: unresolved external symbol _IID_IActiveScriptParse32
ToolBand.obj : error LNK2001: unresolved external symbol _DIID_HTMLWindowEvents2
ToolBandObj.obj : error LNK2001: unresolved external symbol _DIID_HTMLWindowEvents2
ToolBandObj.obj : error LNK2001: unresolved external symbol _CLSID_ToolbarExtButtons
R/toolbar.dll : fatal error LNK1120: 5 unresolved externals
0
Comment
Question by:BrianGEFF719
[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
  • 3
  • 3
7 Comments
 
LVL 86

Accepted Solution

by:
jkr earned 500 total points
ID: 17876736
You need to use

#define INITGUID
#include <initguid.h>
#include <shlguid.h>

in *one* of your source files so that the

DEFINE_GUID(CLSID_ToolbarExtButtons, 0x2ce4b5d8, 0xa28f, 0x11d2, 0x86, 0xc5, 0x0, 0xc0, 0x4f, 0x8e, 0xea, 0x99);

(for example) in 'shlguid.h' will expand to a definition at not only a declaration and the linker can use it for linking.
0
 
LVL 19

Author Comment

by:BrianGEFF719
ID: 17877201
jkr: Same link problems...
0
 
LVL 86

Expert Comment

by:jkr
ID: 17877259
Are you also linking with 'guids.lib'?
0
Industry Leaders: 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!

 
LVL 86

Expert Comment

by:jkr
ID: 17877270
Sorry, 'uuid.lib'.
0
 
LVL 19

Author Comment

by:BrianGEFF719
ID: 17877287
Yes, using uuid.lib.
0
 
LVL 39

Expert Comment

by:itsmeandnobodyelse
ID: 17889538
>>>> 'shlguid.h' will expand to a definition at not only a declaration and the linker can use it for linking.

if the cpp file where you set #define INITGUID  uses precompiled header (PCH) via stdafx.h the INITGUID might be ignored or the header file wouldn't be included cause it is already included by stdafx.h.

To fix that  you should add a new cpp file to your project that contains nothing but

#define INITGUID
#include <initguid.h>
#include <shlguid.h>

as jkr has explained above. To get it compiled you have to right-click the new cpp file in the project (or solution) tree and switch off PCH in the C++ tab of the settings (properties) for that file.

Regards, Alex
0
 
LVL 19

Author Comment

by:BrianGEFF719
ID: 17896013
This problem has been resolved. The original author of the code forgot to send me a folder of headers and library files. Which fixed the problem.


Brian
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Often, when implementing a feature, you won't know how certain events should be handled at the point where they occur and you'd rather defer to the user of your function or class. For example, a XML parser will extract a tag from the source code, wh…
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 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.
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.

752 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