BCB关于动态编译
以下是我在动态编译的时候出现的错误:
[C++ Warning] Dialogs.hpp(437): W8058 Cannot create pre-compiled header: initialized data in header
[Linker Error] Unresolved external 'Shockwaveflashobjects_tlb::CLSID_FlashObject' referenced from C:\PROGRAM FILES (X86)\BORLAND\CBUILDER6\IMPORTS\SHOCKWAVEFLASHOBJECTS_OCX.OBJ
[Linker Error] Unresolved external 'Shockwaveflashobjects_tlb::IID_IFlashObject' referenced from C:\PROGRAM FILES (X86)\BORLAND\CBUILDER6\IMPORTS\SHOCKWAVEFLASHOBJECTS_OCX.OBJ
[Linker Error] Unresolved external 'Shockwaveflashobjects_tlb::CLSID_FlashObjectInterface' referenced from C:\PROGRAM FILES (X86)\BORLAND\CBUILDER6\IMPORTS\SHOCKWAVEFLASHOBJECTS_OCX.OBJ
[Linker Error] Unresolved external 'Shockwaveflashobjects_tlb::IID_IDispatchEx' referenced from C:\PROGRAM FILES (X86)\BORLAND\CBUILDER6\IMPORTS\SHOCKWAVEFLASHOBJECTS_OCX.OBJ
请问下是什么原因导致的?
[解决办法]
第一个C++ Warning W8058,是由于各单元中包含头文件顺序不一致,导致无法创建预编译头,这个只影响编译速度。
后面的Linker Error,是Shockwaveflashobjects_tlb的相关实现部分没有找到,你需要把相关的单元添加到工程中才能正常链接。