读书人

jpg转dcm 编译链接时出的有关问题~请问

发布时间: 2012-08-09 15:59:21 作者: rapoo

jpg转dcm 编译链接时出的问题~~请教啊~~~~
Linking...
Creating library Debug/test.lib and object Debug/test.exp
testDlg.obj : error LNK2001: unresolved external symbol "public: __thiscall DiRegister::DiRegister(void)" (??0DiRegister@@QAE@XZ)
testDlg.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall DiRegister::~DiRegister(void)" (??1DiRegister@@UAE@XZ)
testDlg.obj : error LNK2001: unresolved external symbol "public: int __thiscall DicomImage::writeBMP(char const *,int,unsigned long)" (?writeBMP@DicomImage@@QAEHPBDHK@Z)
testDlg.obj : error LNK2001: unresolved external symbol "public: __thiscall DicomImage::DicomImage(class DcmObject *,enum E_TransferSyntax,unsigned long,unsigned long,unsigned long)" (??0DicomImage@@QAE@PAVDcmObject@@W4E_TransferSyntax@@KKK@Z)
testDlg.obj : error LNK2001: unresolved external symbol "public: enum E_TransferSyntax __thiscall DcmDataset::getOriginalXfer(void)const " (?getOriginalXfer@DcmDataset@@QBE?AW4E_TransferSyntax@@XZ)
testDlg.obj : error LNK2001: unresolved external symbol "public: class DcmDataset * __thiscall DcmFileFormat::getDataset(void)" (?getDataset@DcmFileFormat@@QAEPAVDcmDataset@@XZ)
testDlg.obj : error LNK2001: unresolved external symbol "public: __thiscall DcmFileFormat::DcmFileFormat(void)" (??0DcmFileFormat@@QAE@XZ)
testDlg.obj : error LNK2001: unresolved external symbol "public: virtual __thiscall DcmFileFormat::~DcmFileFormat(void)" (??1DcmFileFormat@@UAE@XZ)
testDlg.obj : error LNK2001: unresolved external symbol "public: virtual class OFCondition __thiscall DcmFileFormat::saveFile(char const *,enum E_TransferSyntax,enum E_EncodingType,enum E_GrpLenEncoding,enum E_PaddingEncoding,unsigned long,unsigned
long,bool)" (?saveFile@DcmFileFormat@@UAE?AVOFCondition@@PBDW4E_TransferSyntax@@W4E_EncodingType@@W4E_GrpLenEncoding@@W4E_PaddingEncoding@@KK_N@Z)
testDlg.obj : error LNK2001: unresolved external symbol "public: class OFCondition __thiscall DcmItem::putAndInsertUint8Array(class DcmTag const &,unsigned char const *,unsigned long,bool)" (?putAndInsertUint8Array@DcmItem@@QAE?AVOFCondition@@ABVDcm
Tag@@PBEK_N@Z)
testDlg.obj : error LNK2001: unresolved external symbol "public: class OFCondition __thiscall DcmItem::putAndInsertUint16(class DcmTag const &,unsigned short,unsigned long,bool)" (?putAndInsertUint16@DcmItem@@QAE?AVOFCondition@@ABVDcmTag@@GK_N@Z)
testDlg.obj : error LNK2001: unresolved external symbol "char * __cdecl dcmGenerateUniqueIdentifier(char *,char const *)" (?dcmGenerateUniqueIdentifier@@YAPADPADPBD@Z)
testDlg.obj : error LNK2001: unresolved external symbol "public: __thiscall DcmTag::~DcmTag(void)" (??1DcmTag@@QAE@XZ)
testDlg.obj : error LNK2001: unresolved external symbol "public: class OFCondition __thiscall DcmItem::putAndInsertString(class DcmTag const &,char const *,bool)" (?putAndInsertString@DcmItem@@QAE?AVOFCondition@@ABVDcmTag@@PBD_N@Z)
testDlg.obj : error LNK2001: unresolved external symbol "public: __thiscall DcmTag::DcmTag(class DcmTagKey const &)" (??0DcmTag@@QAE@ABVDcmTagKey@@@Z)
Debug/test.exe : fatal error LNK1120: 15 unresolved externals
Error executing link.exe.

test.exe - 16 error(s), 0 warning(s)




这是怎么回事 debug和release都不行~~~

[解决办法]
是不是没有添加对相应的库的引用??
[解决办法]
连接不到,应该是C和C++混用的时候造成的,由于命名规则不同所以连接的时候就不同。
另外一种情况是没有响应的库可以连接,只有函数的声明。希望可以帮到你!

读书人网 >C++

热点推荐