-
September 27th, 2012, 10:09 AM
#1
DLL errors in vc++ program
Hi
I'm new to visual c++, but OK with several other languages, however I am having build errors using an external dll in vs2010.
The external dll call is made from a button on a form. The header and lib files are as supplied with the dll, which just controls a digital i/o port. The lib file is referenced in the linker.
my simple code :-
#include <libad.h>
...
adh = ad_open("usb-pio")
Errors on build :-
1>usbpiowf.obj : error LNK2028: unresolved token (0A00000F) "extern "C" int __clrcall ad_open(char const *)" (?ad_open@@$$J0YMHPBD@Z) referenced in function "private: void __clrcall usbpiowf::Form1::button1_Click(class System::Object ^,class System::EventArgs ^)" (?button1_Click@Form1@usbpiowf@@$$FA$AAMXP$AAVObject@System@@P$AAVEventArgs@4@@Z)
1>usbpiowf.obj : error LNK2019: unresolved external symbol "extern "C" int __clrcall ad_open(char const *)" (?ad_open@@$$J0YMHPBD@Z) referenced in function "private: void __clrcall usbpiowf::Form1::button1_Click(class System::Object ^,class System::EventArgs ^)" (?button1_Click@Form1@usbpiowf@@$$FA$AAMXP$AAVObject@System@@P$AAVEventArgs@4@@Z)
1>E:\Microsoft Visual Studio 10.0\My_winform_C_Projects\usbpiowf\Debug\usbpiowf.exe : fatal error LNK1120: 2 unresolved externals
Any help much appreciated.
Best Regards
picclock
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|