2
votes

I can't seem to find any walk-trough on how to create a MFC DLL using Visual Studio 2008. My problem is the following. I need to use wininet.h with my DLL and my solution to that was to use MFC DLL. Anyhow trying to link my project gives me 5 Link errors
I believe that the error is of a kind that I need to add Additional Library Directories. But which one should I add?

void ClearHandles(void) //close all open handlers if any
void SetClientCert(void) //try to set a cert if possible
void FindCertWithOUNITName(void) //This function performs a certificate contex search

All help would be appreciated! I would even appreciate links to tutorials or walk-throughs using a DLL with MFC.

3

3 Answers

4
votes

Add Crypt32.lib to your lib dependencies under Linker/Input - Additional dependencies:

alt text

1
votes

You need to add crypt32.lib to your list of dependencies for the DLL. You can find this in the MSDN page for the API, for example here.

Requirements

Minimum supported client Windows 2000 Professional

Minimum supported server Windows 2000 Server

Header Wincrypt.h

Library Crypt32.lib

DLL Crypt32.dll

0
votes

The Linker IncrBuildImage error is described here:

http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/801ba6d7-a284-4b5d-a75b-3652138d6dff

Perhaps the hotfix would help