Linking errors with MFC Dialog Based application and Crypto++

Hi,

For quite long now I've been trying to get the Crypto++
([url]www.cryptopp.com[/url]) library working with a simple MFC Dialog
Based application.

The strange thing is that a Win32 console application links and works
fine with the same settings :-|

Here are the errors I'm getting:

> 
> --------------------Configuration: dialog - Win32
> Debug--------------------
> Linking...
> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
> std::ios_base::Init::Init(void)" (??0Init@ios_base@std@@QAE@XZ)"
> imported
> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
> std::ios_base::Init::~Init(void)" (??1Init@ios_base@std@@QAE@XZ)"
> imported
> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
> std::_Winit::_Winit(void)" (??0_Winit@std@@QAE@XZ)" imported
> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
> std::_Winit::~_Winit(void)" (??1_Winit@std@@QAE@XZ)" imported
> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
> std::basic_string,class std::allocator >::~basic_string,class
> std::allocator >(void)" (??1?$basic_s
> tring@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@XZ)"
> imported
> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
> std::basic_string,class std::allocator >::basic_string,class
> std::allocator >(char const *,class st
> d::allocator const &)"
> (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@PBDABV?$allocator@D@1@@Z)"
> imported
> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
> std::basic_string,class std::allocator >::basic_string,class
> std::allocator >(class std::basic_stri
> ng,class std::allocator > const &)"
> (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV01@@Z)"
> imported
> LINK : warning LNK4049: locally defined symbol ""public: char const *
> __thiscall std::basic_string,class std::allocator >::c_str(void)const
> " (?c_str@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@st
> d@@QBEPBDXZ)" imported
> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
> symbol ___setlc_active
> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
> symbol ___setlc_active
> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
> symbol ___setlc_active
> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
> ___setlc_active
> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
> ___setlc_active
> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
> symbol ___unguarded_readlc_active
> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
> symbol ___unguarded_readlc_active
> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
> symbol ___unguarded_readlc_active
> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
> ___unguarded_readlc_active
> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
> ___unguarded_readlc_active
> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
> symbol ___lc_handle
> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
> symbol ___lc_handle
> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
> symbol ___lc_handle
> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
> ___lc_handle
> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
> ___lc_handle
> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
> symbol __pctype
> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
> symbol __pctype
> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
> __pctype
> libcpmtd.lib(wlocale.obj) : error LNK2001: unresolved external symbol
> ___mb_cur_max
> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
> symbol ___mb_cur_max
> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
> symbol ___mb_cur_max
> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
> ___mb_cur_max
> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
> ___mb_cur_max
> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
> symbol ___lc_codepage
> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
> symbol ___lc_codepage
> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
> ___lc_codepage
> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
> ___lc_codepage
> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
> symbol ___lc_collate_cp
> Debug/dialog.exe : fatal error LNK1120: 7 unresolved externals
> Error executing link.exe.
> 
> dialog.exe - 29 error(s), 8 warning(s)
> 


I've followed this tutorial:

[url]http://www.codeproject.com/cpp/dirtypad.asp[/url]

with no luck

Here is some of the (I believe) relevant code:
- StdAfx.h
> 
> // stdafx.h : include file for standard system include files,
> // or project specific include files that are used frequently, but
> // are changed infrequently
> //
> 
> #if
> !defined(AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_)
> #define
> AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_
> 
> #if _MSC_VER > 1000
> #pragma once
> #endif // _MSC_VER > 1000
> 
> #define VC_EXTRALEAN // Exclude rarely-used stuff from Windows
> headers
> 
> #include // MFC core and standard components
> #include // MFC extensions
> #include // MFC Automation classes
> #include // MFC support for Internet Explorer 4 Common Controls
> #ifndef _AFX_NO_AFXCMN_SUPPORT
> #include // MFC support for Windows Common Controls
> #endif // _AFX_NO_AFXCMN_SUPPORT
> 
> 
> #pragma comment( linker, "/NODEFAULTLIB:msvcprtd.lib" )
> #pragma comment( linker, "/NODEFAULTLIB:libcmtd.lib" )
> #pragma comment( linker, "/NODEFAULTLIB:msvcprt.lib" )
> #pragma comment( linker, "/NODEFAULTLIB:libcmt.lib" )
> 
> 
> 
> //{{AFX_INSERT_LOCATION}}
> // Microsoft Visual C++ will insert additional declarations
> immediately before the previous line.
> 
> #endif //
> !defined(AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_)
> 
> 

- dialogDlg.cpp
> 
> // dialogDlg.cpp : implementation file
> //
> 
> #include "stdafx.h"
> #include "dialog.h"
> #include "dialogDlg.h"
> 
> #include "pch.h"
> 
> #include "base64.h"
> #include "md5.h"
> #include "sha.h"
> #include "ripemd.h"
> #include "files.h"
> #include "rng.h"
> #include "hex.h"
> #include "gzip.h"
> #include "default.h"
> #include "osrng.h"
> #include "rsa.h"
> #include "randpool.h"
> #include "ida.h"
> #include "socketft.h"
> 
> #include "validate.h"
> #include "bench.h"
> 
> #include
> 
> #if (_MSC_VER >= 1000)
> #include // for the debug heap
> #endif
> 
> #if defined(__MWERKS__) && defined(macintosh)
> #include
> #endif
> 
> USING_NAMESPACE(CryptoPP)
> USING_NAMESPACE(std)
> ...
> 


Maybe there's something wrong with my configuration? Or with my VC++
instalation? Some library is still missing?

I was suggested that there could be something wrong with Calling /
Naming convention but changing Calling convention didn't help

I've tried switching many options in Project -> Setting but neither
helped.

I'm really in need of help

If needed I can gladly give more code snippets...

Best regards,
Maciej Zieba



--
Crocodil
------------------------------------------------------------------------
Posted via http://www.codecomments.com
------------------------------------------------------------------------
 
0
5/4/2005 10:42:12 PM
vc.mfc 33608 articles. 0 followers. Follow

2 Replies
753 Views

Similar Articles

[PageSpeed] 56

Alright Crocodil, I believe what you need to do is add a namespace into your 
code. (So at the beginning of the code you will need to add a line like
USING_NAMESPACE(CryptoPP)  (check the file dlltest.cpp in the crypto 
download to see what I mean).   In case you are not familiar with 
namespaces, this page has a good description, 
http://www.codeproject.com/cpp/using_namespaces.asp

Essentially the problem is that these function are defined twice, I believe 
that the use of namespaces should help resolve this problem.

Lates,

Daemon


"Crocodil" <Crocodil.1ojd1r@mail.codecomments.com> wrote in message 
news:Crocodil.1ojd1r@mail.codecomments.com...
>
> Hi,
>
> For quite long now I've been trying to get the Crypto++
> ([url]www.cryptopp.com[/url]) library working with a simple MFC Dialog
> Based application.
>
> The strange thing is that a Win32 console application links and works
> fine with the same settings :-|
>
> Here are the errors I'm getting:
>
>>
>> --------------------Configuration: dialog - Win32
>> Debug--------------------
>> Linking...
>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>> std::ios_base::Init::Init(void)" (??0Init@ios_base@std@@QAE@XZ)"
>> imported
>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>> std::ios_base::Init::~Init(void)" (??1Init@ios_base@std@@QAE@XZ)"
>> imported
>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>> std::_Winit::_Winit(void)" (??0_Winit@std@@QAE@XZ)" imported
>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>> std::_Winit::~_Winit(void)" (??1_Winit@std@@QAE@XZ)" imported
>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>> std::basic_string,class std::allocator >::~basic_string,class
>> std::allocator >(void)" (??1?$basic_s
>> tring@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@XZ)"
>> imported
>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>> std::basic_string,class std::allocator >::basic_string,class
>> std::allocator >(char const *,class st
>> d::allocator const &)"
>> (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@PBDABV?$allocator@D@1@@Z)"
>> imported
>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>> std::basic_string,class std::allocator >::basic_string,class
>> std::allocator >(class std::basic_stri
>> ng,class std::allocator > const &)"
>> (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV01@@Z)"
>> imported
>> LINK : warning LNK4049: locally defined symbol ""public: char const *
>> __thiscall std::basic_string,class std::allocator >::c_str(void)const
>> " (?c_str@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@st
>> d@@QBEPBDXZ)" imported
>> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
>> symbol ___setlc_active
>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>> symbol ___setlc_active
>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>> symbol ___setlc_active
>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>> ___setlc_active
>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>> ___setlc_active
>> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
>> symbol ___unguarded_readlc_active
>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>> symbol ___unguarded_readlc_active
>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>> symbol ___unguarded_readlc_active
>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>> ___unguarded_readlc_active
>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>> ___unguarded_readlc_active
>> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
>> symbol ___lc_handle
>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>> symbol ___lc_handle
>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>> symbol ___lc_handle
>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>> ___lc_handle
>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>> ___lc_handle
>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>> symbol __pctype
>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>> symbol __pctype
>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>> __pctype
>> libcpmtd.lib(wlocale.obj) : error LNK2001: unresolved external symbol
>> ___mb_cur_max
>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>> symbol ___mb_cur_max
>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>> symbol ___mb_cur_max
>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>> ___mb_cur_max
>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>> ___mb_cur_max
>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>> symbol ___lc_codepage
>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>> symbol ___lc_codepage
>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>> ___lc_codepage
>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>> ___lc_codepage
>> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
>> symbol ___lc_collate_cp
>> Debug/dialog.exe : fatal error LNK1120: 7 unresolved externals
>> Error executing link.exe.
>>
>> dialog.exe - 29 error(s), 8 warning(s)
>>
>
>
> I've followed this tutorial:
>
> [url]http://www.codeproject.com/cpp/dirtypad.asp[/url]
>
> with no luck
>
> Here is some of the (I believe) relevant code:
> - StdAfx.h
>>
>> // stdafx.h : include file for standard system include files,
>> // or project specific include files that are used frequently, but
>> // are changed infrequently
>> //
>>
>> #if
>> !defined(AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_)
>> #define
>> AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_
>>
>> #if _MSC_VER > 1000
>> #pragma once
>> #endif // _MSC_VER > 1000
>>
>> #define VC_EXTRALEAN // Exclude rarely-used stuff from Windows
>> headers
>>
>> #include // MFC core and standard components
>> #include // MFC extensions
>> #include // MFC Automation classes
>> #include // MFC support for Internet Explorer 4 Common Controls
>> #ifndef _AFX_NO_AFXCMN_SUPPORT
>> #include // MFC support for Windows Common Controls
>> #endif // _AFX_NO_AFXCMN_SUPPORT
>>
>>
>> #pragma comment( linker, "/NODEFAULTLIB:msvcprtd.lib" )
>> #pragma comment( linker, "/NODEFAULTLIB:libcmtd.lib" )
>> #pragma comment( linker, "/NODEFAULTLIB:msvcprt.lib" )
>> #pragma comment( linker, "/NODEFAULTLIB:libcmt.lib" )
>>
>>
>>
>> //{{AFX_INSERT_LOCATION}}
>> // Microsoft Visual C++ will insert additional declarations
>> immediately before the previous line.
>>
>> #endif //
>> !defined(AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_)
>>
>>
>
> - dialogDlg.cpp
>>
>> // dialogDlg.cpp : implementation file
>> //
>>
>> #include "stdafx.h"
>> #include "dialog.h"
>> #include "dialogDlg.h"
>>
>> #include "pch.h"
>>
>> #include "base64.h"
>> #include "md5.h"
>> #include "sha.h"
>> #include "ripemd.h"
>> #include "files.h"
>> #include "rng.h"
>> #include "hex.h"
>> #include "gzip.h"
>> #include "default.h"
>> #include "osrng.h"
>> #include "rsa.h"
>> #include "randpool.h"
>> #include "ida.h"
>> #include "socketft.h"
>>
>> #include "validate.h"
>> #include "bench.h"
>>
>> #include
>>
>> #if (_MSC_VER >= 1000)
>> #include // for the debug heap
>> #endif
>>
>> #if defined(__MWERKS__) && defined(macintosh)
>> #include
>> #endif
>>
>> USING_NAMESPACE(CryptoPP)
>> USING_NAMESPACE(std)
>> ...
>>
>
>
> Maybe there's something wrong with my configuration? Or with my VC++
> instalation? Some library is still missing?
>
> I was suggested that there could be something wrong with Calling /
> Naming convention but changing Calling convention didn't help
>
> I've tried switching many options in Project -> Setting but neither
> helped.
>
> I'm really in need of help
>
> If needed I can gladly give more code snippets...
>
> Best regards,
> Maciej Zieba
>
>
>
> --
> Crocodil
> ------------------------------------------------------------------------
> Posted via http://www.codecomments.com
> ------------------------------------------------------------------------
> 


0
Arlis
5/6/2005 4:06:33 PM
Oh and the error 2001 usually is a result that it cannot find the necessary 
..lib file.  Make sure that under your configuration properties -> linker you 
have the "addition library" where the .lib file is found added, and that the 
..lib file is added to the input->addition dependencies.

"Arlis Rose" <arlisATendevouraerospace.com> wrote in message 
news:OTdOZVlUFHA.1796@TK2MSFTNGP15.phx.gbl...
> Alright Crocodil, I believe what you need to do is add a namespace into 
> your code. (So at the beginning of the code you will need to add a line 
> like
> USING_NAMESPACE(CryptoPP)  (check the file dlltest.cpp in the crypto 
> download to see what I mean).   In case you are not familiar with 
> namespaces, this page has a good description, 
> http://www.codeproject.com/cpp/using_namespaces.asp
>
> Essentially the problem is that these function are defined twice, I 
> believe that the use of namespaces should help resolve this problem.
>
> Lates,
>
> Daemon
>
>
> "Crocodil" <Crocodil.1ojd1r@mail.codecomments.com> wrote in message 
> news:Crocodil.1ojd1r@mail.codecomments.com...
>>
>> Hi,
>>
>> For quite long now I've been trying to get the Crypto++
>> ([url]www.cryptopp.com[/url]) library working with a simple MFC Dialog
>> Based application.
>>
>> The strange thing is that a Win32 console application links and works
>> fine with the same settings :-|
>>
>> Here are the errors I'm getting:
>>
>>>
>>> --------------------Configuration: dialog - Win32
>>> Debug--------------------
>>> Linking...
>>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>>> std::ios_base::Init::Init(void)" (??0Init@ios_base@std@@QAE@XZ)"
>>> imported
>>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>>> std::ios_base::Init::~Init(void)" (??1Init@ios_base@std@@QAE@XZ)"
>>> imported
>>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>>> std::_Winit::_Winit(void)" (??0_Winit@std@@QAE@XZ)" imported
>>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>>> std::_Winit::~_Winit(void)" (??1_Winit@std@@QAE@XZ)" imported
>>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>>> std::basic_string,class std::allocator >::~basic_string,class
>>> std::allocator >(void)" (??1?$basic_s
>>> tring@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@XZ)"
>>> imported
>>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>>> std::basic_string,class std::allocator >::basic_string,class
>>> std::allocator >(char const *,class st
>>> d::allocator const &)"
>>> (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@PBDABV?$allocator@D@1@@Z)"
>>> imported
>>> LINK : warning LNK4049: locally defined symbol ""public: __thiscall
>>> std::basic_string,class std::allocator >::basic_string,class
>>> std::allocator >(class std::basic_stri
>>> ng,class std::allocator > const &)"
>>> (??0?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV01@@Z)"
>>> imported
>>> LINK : warning LNK4049: locally defined symbol ""public: char const *
>>> __thiscall std::basic_string,class std::allocator >::c_str(void)const
>>> " (?c_str@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@st
>>> d@@QBEPBDXZ)" imported
>>> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
>>> symbol ___setlc_active
>>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>>> symbol ___setlc_active
>>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>>> symbol ___setlc_active
>>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>>> ___setlc_active
>>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>>> ___setlc_active
>>> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
>>> symbol ___unguarded_readlc_active
>>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>>> symbol ___unguarded_readlc_active
>>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>>> symbol ___unguarded_readlc_active
>>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>>> ___unguarded_readlc_active
>>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>>> ___unguarded_readlc_active
>>> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
>>> symbol ___lc_handle
>>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>>> symbol ___lc_handle
>>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>>> symbol ___lc_handle
>>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>>> ___lc_handle
>>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>>> ___lc_handle
>>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>>> symbol __pctype
>>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>>> symbol __pctype
>>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>>> __pctype
>>> libcpmtd.lib(wlocale.obj) : error LNK2001: unresolved external symbol
>>> ___mb_cur_max
>>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>>> symbol ___mb_cur_max
>>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>>> symbol ___mb_cur_max
>>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>>> ___mb_cur_max
>>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>>> ___mb_cur_max
>>> libcpmtd.lib(_tolower.obj) : error LNK2001: unresolved external
>>> symbol ___lc_codepage
>>> libcpmtd.lib(_toupper.obj) : error LNK2001: unresolved external
>>> symbol ___lc_codepage
>>> libcpmtd.lib(xwctomb.obj) : error LNK2001: unresolved external symbol
>>> ___lc_codepage
>>> libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol
>>> ___lc_codepage
>>> libcpmtd.lib(xstrcoll.obj) : error LNK2001: unresolved external
>>> symbol ___lc_collate_cp
>>> Debug/dialog.exe : fatal error LNK1120: 7 unresolved externals
>>> Error executing link.exe.
>>>
>>> dialog.exe - 29 error(s), 8 warning(s)
>>>
>>
>>
>> I've followed this tutorial:
>>
>> [url]http://www.codeproject.com/cpp/dirtypad.asp[/url]
>>
>> with no luck
>>
>> Here is some of the (I believe) relevant code:
>> - StdAfx.h
>>>
>>> // stdafx.h : include file for standard system include files,
>>> // or project specific include files that are used frequently, but
>>> // are changed infrequently
>>> //
>>>
>>> #if
>>> !defined(AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_)
>>> #define
>>> AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_
>>>
>>> #if _MSC_VER > 1000
>>> #pragma once
>>> #endif // _MSC_VER > 1000
>>>
>>> #define VC_EXTRALEAN // Exclude rarely-used stuff from Windows
>>> headers
>>>
>>> #include // MFC core and standard components
>>> #include // MFC extensions
>>> #include // MFC Automation classes
>>> #include // MFC support for Internet Explorer 4 Common Controls
>>> #ifndef _AFX_NO_AFXCMN_SUPPORT
>>> #include // MFC support for Windows Common Controls
>>> #endif // _AFX_NO_AFXCMN_SUPPORT
>>>
>>>
>>> #pragma comment( linker, "/NODEFAULTLIB:msvcprtd.lib" )
>>> #pragma comment( linker, "/NODEFAULTLIB:libcmtd.lib" )
>>> #pragma comment( linker, "/NODEFAULTLIB:msvcprt.lib" )
>>> #pragma comment( linker, "/NODEFAULTLIB:libcmt.lib" )
>>>
>>>
>>>
>>> //{{AFX_INSERT_LOCATION}}
>>> // Microsoft Visual C++ will insert additional declarations
>>> immediately before the previous line.
>>>
>>> #endif //
>>> !defined(AFX_STDAFX_H__C79FF988_1405_4A43_A1AF_A9DF5EC942C9__INCLUDED_)
>>>
>>>
>>
>> - dialogDlg.cpp
>>>
>>> // dialogDlg.cpp : implementation file
>>> //
>>>
>>> #include "stdafx.h"
>>> #include "dialog.h"
>>> #include "dialogDlg.h"
>>>
>>> #include "pch.h"
>>>
>>> #include "base64.h"
>>> #include "md5.h"
>>> #include "sha.h"
>>> #include "ripemd.h"
>>> #include "files.h"
>>> #include "rng.h"
>>> #include "hex.h"
>>> #include "gzip.h"
>>> #include "default.h"
>>> #include "osrng.h"
>>> #include "rsa.h"
>>> #include "randpool.h"
>>> #include "ida.h"
>>> #include "socketft.h"
>>>
>>> #include "validate.h"
>>> #include "bench.h"
>>>
>>> #include
>>>
>>> #if (_MSC_VER >= 1000)
>>> #include // for the debug heap
>>> #endif
>>>
>>> #if defined(__MWERKS__) && defined(macintosh)
>>> #include
>>> #endif
>>>
>>> USING_NAMESPACE(CryptoPP)
>>> USING_NAMESPACE(std)
>>> ...
>>>
>>
>>
>> Maybe there's something wrong with my configuration? Or with my VC++
>> instalation? Some library is still missing?
>>
>> I was suggested that there could be something wrong with Calling /
>> Naming convention but changing Calling convention didn't help
>>
>> I've tried switching many options in Project -> Setting but neither
>> helped.
>>
>> I'm really in need of help
>>
>> If needed I can gladly give more code snippets...
>>
>> Best regards,
>> Maciej Zieba
>>
>>
>>
>> --
>> Crocodil
>> ------------------------------------------------------------------------
>> Posted via http://www.codecomments.com
>> ------------------------------------------------------------------------
>>
>
> 


0
Arlis
5/6/2005 4:16:54 PM
Reply:

Similar Artilces:

OMA internal server error 500
Hello - I've just tried to get OMA setup and I've encountered th following error http: error 500 (internal server error Runtime erro <!-- Web.Config Configuration File -- <configuration <system.web <customErrors mode="Off"/ </system.web </configuration to display error messag Having changed the web.config file the error still persists This occurs when I logon with domain\username: passwor What is the problem? There are a few posts relating to this but n responses - if anyone responds to this I'll be most greatful ...

Excel hart has OLE onject errors in Access 2007
I am trying to build a chart on a form in Access 2007. I have already created it in Excel and want it to look the same but it seems that the formatting options are greatly reduced, fewer chart options, and formatting variations in Access. I tried to copy and paste the chart from Excel 2007 onto my Access form, and gave it the query as the data source but got messages "The operation on the OLE object failed. The OLE server may not be registered. To register the OLE server, reinstall it." If I remove the name of the query I get an identical chart to the one in Excel, ...

MFC serialization of HICON
I'm using standard MFC serialization mechanism to save an icon. After upgrade to VS 2008 my serialization code stop working. Saving seems to work fine, but when it comes to open HICON can not be loaded. I have narrowed it down to GDIplus dll trying to create mask bitmap for the icon from stream (standard MFC serialization). This operation always fails. Here is my simple serialization code: void CMyObject::Serialize(CArchive &ar) { CObject::Serialize(ar); if( ar.IsStoring() ) { ar << m_hIcon; } else { ar >> m_hIcon; } } m_hIcon obviously is type of the HICON....

Change link between form and subform
I have a form with a subform in it. I would like to change the way they are linked so instead of linking from Old ID, they link to New ID I don't know anything about code, is there a way to just change the cell it relies on? Thanks C Confused87 - Bring up the properties of the subform, and change the values in 'Link Child Fields' and 'Link Master Fields' on the Data tab of the properties dialog box. Make sure you have the subform selected, not the form within the subform. -- Daryl S "Confused87" wrote: > I have a form with...

linking #4
I am trying to link and .slk file to a .xls file all the links appear to be updating but i keep getting a message that excel cannot update 1 or all of the links. Is this common when linking with an .slk because i have several linked wrk books and have never had this problem. thanks Dean ...

Linked Forms
Hello, I am doing a project that requires two forms.. The first form contains the data for a business the second form contains data for the business owner... How do I link the two forms together...? Many thanks. Bob Send a common key piece of data from the first form (say the company name) to the second form page and include it in the second form as a hidden form field (then if using a database to store the results link with a relationship the 2 results tables by the common field) For form passing information see http://irt.org/articles/js063/index.htm -- ____...

Text on cart based on data in a cell
I have a chart on a separate sheet witch is based on a filtered list on another sheet. I would like to label my chart to show witch filter as been applied, is this possible? (Ho, and if so, how would I do it?) Thanks for any help. Select the chart, press the equal key, then select the cell with a mouse. This adds a text box in the middle of the chart, which you can move around and format as needed. - Jon ------- Jon Peltier, Microsoft Excel MVP Peltier Technical Services Tutorials and Custom Solutions http://PeltierTech.com/ _______ Ant wrote: > I have a chart on a separate s...

Links not linking
Hello I have written a fairly big spreadsheet linking through the pages with SUM, SUMIF and SUMPRODUCT formula's What I am now finding is that when I update one page it doesn't update the rest, even if I am only typing in a figure to the SUM function. I have check and the calculations function is on automatic. is there a fix or something that I could run to make sure that all the formulas are working correctly. thanks Just a guess (since you already checked tools|options|calculation tab). How about selecting all the cells (ctrl-a (twice in xl2003)) and then edit|replace what: ...

Linked Table Manager in ACCESS
Hi, I am trying to change a field in an ACCESS table and get an error message that says the table is a linked table and fields can't be changed. After googling for some answers, I think I should be able to find out the link using "Linked Table Manager" in ACCESS. However, the "Linked Table Manager" button is grayed out. Any ideas/suggestions are welcome. Thanks. Richard Open the table in Design View. Reduce the window so that you can see the window's top bar. Right click in the top bar of the window (usually blue in color) and select ...

e-connect error after install hotfix
Hi i have security problem with e-connect after install kb902400 on server2003 sp1 if i uninstall kb902400 the module run well. i talk to my MBS about this problem, but he says the problem came from microsoft in e-connect module itself. some one have a work around. thx ...

Copy-Paste Value based on user defined range
Hello, I am trying to create an option such that, the user can input a default value in one cell, enter a start year, and the number of years he wants to assign this value for. Ex. A B C 1 Value Start Year # of Years 2 500 2005 5 Apply 500 starting in 2005 for the next five years including 2005. I am working in Excel2000. Thanks for your help ...

Link To A Cell From Chart
Hi all. I have a text box in a chart worksheet. Can I link it to an information from any cell in other worksheet in the same workbook. Thanks. Yes. Click the text box icon, then click on the chart sheet to insert the text box. Click in the formula bar and =Sheet1!A2 (or whatever cell you want to link). -- Greeting from the Gulf Coast! http://myweb.cableone.net/twodays "Salza" <salza@tm.net.my> wrote in message news:3fbfb0bf_2@news.tm.net.my... > Hi all. > I have a text box in a chart worksheet. Can I link it to an information from > any cell in other worksheet in...

Email Server is offline error msg
Hello, I upgraded a user's Office XP that didn't have any SPs to SP2. Now when she double-clicks the Outlook icon, the "Email Server is offline" error message is displayed. When she clicks on retry, her Outlook launches okay and her inbox appears. And her email appears to work okay. Does anyone know how to fix the error message? Thanks, Millie Sounds like a name resolution problem to me. Can you ping the Exchange server, by name, from the affected workstation? -- Aloha, -Ben- Ben M. Schorr, OneNote-MVP http://home.hawaii.rr.com/schorr **I apologize but I am unab...

links
Dear All, It is very critical for my business to learn the basics and the backbone of links in Excel. Are there any tutorials or articles that gives wealth of information about MS Excel links? (in Excel 9.0.6) Web addresses are also welcome. You can also post to my e-mail above. Thank you in advance. Mustafa .. I would advise you go to the newsgroup "microsoft.public.excel.links", and read everything you can about their troubles there and the solutions......... Vaya con Dios, Chuck, CABGx3 "Mustafa" <anonymous@discussions.microsoft.com> wrote in messag...

Knowledge Base Little to be Desired
I don't know if it's just me but I can never find anything I can use to fix my issues in the knowledge base, ever since I started using it before 2000. On top of that according to the site and my maintenance aggreement I should be getting replies on my posts here within 2 days but never do. I'm going to give this one a shot. My issue today is that I have a Invoice from a vendor that needs to be paid. When I go to auto invoice the PO doesn't show up for that Vendor. If I try to input it manually it says that it's already been invoiced. This is not the case, ho...

Linked Tables Over A LAN
Hi, I have a problem with a PC that is sharing an Access database over a LAN. I'm hoping someone may be able to give me a little advice. By the way, I'm a bit of an amatuer so go easy on the technical terminology ;-). I've got four PCs networked through a router which provides internet access. Two PCs are running XP Pro and two are running Vista Business 32bit. One Vista machine holds my full database while the other PCs have a similar database but with tables linked to the first machine. Been running this setup for several years, on various older PCs, with no problems. My proble...

Links
Every time I open a spesific workbook, I get the question if I want t use the old or the new data. This is very irritating! How do I disabl the link that is the reason for this message??? Please help me befor this drives me CRAZY!! ----------------------------------------------- ~~ Message posted from http://www.ExcelTip.com ~~View and post usenet messages directly from http://www.ExcelForum.com Siri You will have a formula somewhere within the wordbook that is linked to another workbook. You can look for them manually and the copy>paste special>values... to kill it. or you could d...

Error R6025
Please help... I am (trying to) run office 2000 and Microsoft XP... (I'm wondering if the combo is the problem) I CANNOT open Office for more than 30 seconds. I get Runtime error R6025! Any suggestions would be helpful.. I've done searches and reinstalled Office 2000... so far.. NADA! ...

email links in Publisher pdf
Why won't Publisher 2007 convert my email links correctly when saved in pdf format? It puts "mail to:" in twice automatically. It is converting website links without a problem. If memory serves the Office 2007 SP1 fixed this in Publisher. The SP2 is also now available. There have been some reports of not being able to open existing Publisher files after installing it, and a report that a fix for that bug is due by the end of the month....you might want to wait to install SP2 until after the first of the month, or just install SP1. DavidF "Rora" <Rora@discu...

Chart template and links
Hi, I have something "strange " (at least for me) going on ... I have an xls workbook, containing some data sheets and also 3 chart templates. These chart templates are copied via a macro to the output xls with the statement : Sheets(ChartName) _ .Copy Before:=Workbooks(targetfile.Window).Sheets(1) When I now look to this chart template in the output xls I got a link to the original xls workbook in which the macro is running. (I can see that via EDIT>LINKS...) Now I do NOT want that link to the originator xls workbook at all ! Is there anybody who knows how I can co...

How can I terminate a Dialog object?
Hey,All! I am now trying to terminate a dialog object,but I do not know how I can terminate it, can anybody tell me how many method I can close it? Thanks in advance! You must be having OK and Cancel button on your Dialog, click one of them. Or if problem is other than this, then post some code, that why you are not able to kill/ close the dialog. Good Luck! "Carl" <carl8421@126.com> wrote in message news:eYuSBvdVFHA.1796@TK2MSFTNGP15.phx.gbl... > Hey,All! > > I am now trying to terminate a dialog object,but I do not know how I can > terminate it, can anybody ...

CSocket pump message error again and again ...
Hi, I have a serious probleme with my CSocket. I have a thread that is using a CSocket to send and receive data. I use the Attach/detach function to put my socket in the thread. All works wonderfully .... 97% of the time. Sometimes, when i really try to make my application crash (by sending many datas with Send) the i got the assertion in the following function BOOL CSocket::PumpMessages(UINT uStopFlag) { <snip> ASSERT(pState->m_hSocketWindow != NULL); // << Assertion here I read so many post speaking about this problem .... but my case is specific: - My socket work...

Linking to ODBC Linked Tables
Hi: I wonder if you have any suggestions for this. We have moved our Access tables into Oracle and have created a MS Access Database that links to these ODBC tables. Each of our users has a local copy of our Reporting Database that formerly linked to Access tables, but now we want them to link to the Ms Access Database which contains the linked ODBC tables on our shared drive. In trying to link to already linked ODBC tables, Access gives an error and will not link to these tables. Is there a way to let our users link to the Access database that contains the linked ODBC tables? Any...

Linked Graphs from Excel
I have linked graphs from excel into my publisher document using Paste Special. The problem is that when they paste in they reshape (I have pie charts and they come in publisher looking like tall skinny ovals). I can fix the shape of the charts manually after pasting them in, but when I update the links the reshaping reverts to its original, incorrect size. Any suggestions on how I can use the linking to excel and not have to resize every time I update? "Paste Special" as what format? Have you tried an image format? -- Mary Sauer MSFT MVP http://office.microsoft.com/ http...

"Get-ClusterResource" cmdlet throws "not recognized as a cmdlet, function, operable program, or script file" error.
Hi, I am trying to use "Get-ClusterResource" cmdlet to fetch "File Share Witness" property of CCR cluster. But when I run this command no "Exchange Management Shell" I am getting "The term 'Get- ClusterResource' is not recognized as a cmdlet, function, operable program, or script file. Verify the term and try again." error. Any idea why I am getting this error? Do I need to add any "PSSnapin" via Add-PSSnapin cmdlet ? If so which one it is? Basically I am not able to run any of the cluster related GET cmdlets on Exchange Managem...