login about faq

Hello,

Trying to run the encription c++ example for hash. https://www.example-code.com/cpp/crypt2_md5_hash_file.asp

I created a project in MSVC 12 and added the include and lib for the crypt download from your site. I also add libs to link with to to the project crypt32.lib and advapi32.lib

Where did I go wrong ...?

I get the following errors. Assume I am missing an library to link with ...

Thanks!

The errors Error 9 error LNK1120: 8 unresolved externals C:dvjspasswordcppexample_passwordDebugexample_password.exe example_password Error 3 error LNK2019: unresolved external symbol "public: thiscall CkCrypt2::CkCrypt2(void)" (??0CkCrypt2@@QAE@XZ) referenced in function "void cdecl sample(void)" (?sample@@YAXXZ) C:dvjspasswordcppexample_passwordexample_passwordexample_password.obj example_password Error 8 error LNK2019: unresolved external symbol "public: bool thiscall CkCrypt2::UnlockComponent(char const *)" (?UnlockComponent@CkCrypt2@@QAE_NPBD@Z) referenced in function "void cdecl sample(void)" (?sample@@YAXXZ) C:dvjspasswordcppexample_passwordexample_passwordexample_password.obj example_password Error 1 error LNK2019: unresolved external symbol "public: bool thiscall CkMultiByteBase::get_LastMethodSuccess(void)" (?get_LastMethodSuccess@CkMultiByteBase@@QAE_NXZ) referenced in function "void cdecl sample(void)" (?sample@@YAXXZ) C:dvjspasswordcppexample_passwordexample_passwordexample_password.obj example_password Error 7 error LNK2019: unresolved external symbol "public: char const * thiscall CkCrypt2::hashFileENC(char const *)" (?hashFileENC@CkCrypt2@@QAEPBDPBD@Z) referenced in function "void cdecl sample(void)" (?sample@@YAXXZ) C:dvjspasswordcppexample_passwordexample_passwordexample_password.obj example_password Error 2 error LNK2019: unresolved external symbol "public: char const * thiscall CkMultiByteBase::lastErrorText(void)" (?lastErrorText@CkMultiByteBase@@QAEPBDXZ) referenced in function "void cdecl sample(void)" (?sample@@YAXXZ) C:dvjspasswordcppexample_passwordexample_passwordexample_password.obj example_password Error 4 error LNK2019: unresolved external symbol "public: virtual thiscall CkCrypt2::~CkCrypt2(void)" (??1CkCrypt2@@UAE@XZ) referenced in function "void cdecl sample(void)" (?sample@@YAXXZ) C:dvjspasswordcppexample_passwordexample_passwordexample_password.obj example_password Error 5 error LNK2019: unresolved external symbol "public: void thiscall CkCrypt2::put_EncodingMode(char const *)" (?put_EncodingMode@CkCrypt2@@QAEXPBD@Z) referenced in function "void cdecl sample(void)" (?sample@@YAXXZ) C:dvjspasswordcppexample_passwordexample_passwordexample_password.obj example_password Error 6 error LNK2019: unresolved external symbol "public: void thiscall CkCrypt2::put_HashAlgorithm(char const *)" (?put_HashAlgorithm@CkCrypt2@@QAEXPBD@Z) referenced in function "void cdecl sample(void)" (?sample@@YAXXZ) C:dvjspasswordcppexample_passwordexample_passwordexample_password.obj example_password

asked Dec 07 '16 at 09:15

evan's gravatar image

evan
1


Somehow you're not actually linking with the Chilkat .lib

It's just a matter of updating your MSVC project settings to link with the matching .lib contained in the download. (You choose the .lib based on the runtime, i.e.. Release vs. Debug, Static vs. "DLL")

link

answered Dec 08 '16 at 07:53

chilkat's gravatar image

chilkat ♦♦
12.8k317366476

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or __italic__
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×20

Asked: Dec 07 '16 at 09:15

Seen: 466 times

Last updated: Dec 08 '16 at 07:53

powered by OSQA