Microsoft KB Archive/174403: Difference between revisions

From BetaArchive Wiki
(importing KB archive)
 
m (Text replacement - """ to """)
 
Line 44: Line 44:
== SYMPTOMS ==
== SYMPTOMS ==


When rebuilding Mfc42.dll, Mfcd42d.dll, or Mfcd42ud.dll after installing Visual Studio 97 Service Pack 1 or Service Pack 2, the "LNK2001: unresolved external symbol" error message occurs for the following functions:
When rebuilding Mfc42.dll, Mfcd42d.dll, or Mfcd42ud.dll after installing Visual Studio 97 Service Pack 1 or Service Pack 2, the "LNK2001: unresolved external symbol" error message occurs for the following functions:
<div class="indent">
<div class="indent">


Line 93: Line 93:
== MORE INFORMATION ==
== MORE INFORMATION ==


The difference between the function definitions in Dbcore.cpp and Mfc42.def, Mfcd42d.def, or Mfcd42ud.def is that the function definitions have an &quot;A&quot; appended to the function names in Mfc42.def, Mfcd42d.def, or Mfcd42ud.def.<br />
The difference between the function definitions in Dbcore.cpp and Mfc42.def, Mfcd42d.def, or Mfcd42ud.def is that the function definitions have an "A" appended to the function names in Mfc42.def, Mfcd42d.def, or Mfcd42ud.def.<br />
<br />
<br />
These functions exist in Dbcore.cpp without the &quot;A&quot; appended to the function name.<br />
These functions exist in Dbcore.cpp without the "A" appended to the function name.<br />
<br />
<br />
Remove the &quot;A&quot; from the function names in question for the .def file you specify when rebuilding Mfc42.dll, Mfcd42d.dll, or Mfcd42ud.dll.<br />
Remove the "A" from the function names in question for the .def file you specify when rebuilding Mfc42.dll, Mfcd42d.dll, or Mfcd42ud.dll.<br />
<br />
<br />
For example:<br />
For example:<br />
Line 113: Line 113:
== REFERENCES ==
== REFERENCES ==


See the section &quot;Building the MFC DLL&quot; in TN033 for information on how to rebuild the MFC DLL.<br />
See the section "Building the MFC DLL" in TN033 for information on how to rebuild the MFC DLL.<br />
<br />
<br />
(c) Microsoft Corporation 1997, All Rights Reserved. Contributions by Isaac Varon, Microsoft Corporation.
(c) Microsoft Corporation 1997, All Rights Reserved. Contributions by Isaac Varon, Microsoft Corporation.

Latest revision as of 11:07, 21 July 2020

Article ID: 174403

Article Last Modified on 11/21/2006



APPLIES TO

  • Microsoft Foundation Class Library 4.2



This article was previously published under Q174403

SYMPTOMS

When rebuilding Mfc42.dll, Mfcd42d.dll, or Mfcd42ud.dll after installing Visual Studio 97 Service Pack 1 or Service Pack 2, the "LNK2001: unresolved external symbol" error message occurs for the following functions:

AfxThunkSQLDescribeColA
AfxThunkSQLDriverConnectA
AfxThunkSQLErrorA
AfxThunkSQLExecDirectA
AfxThunkSQLGetCursorNameA
AfxThunkSQLGetInfoA
AfxThunkSQLPrepareA
AfxThunkSQLSetConnectOptionA


CAUSE

The symbols generated for these functions when compiling the file Dbcore.cpp do not match the function definitions specified for export in Mfc42.def, Mfcd42d.def, or Mfcd42ud.def.

RESOLUTION

Modify the function definitions in Mfc42.def, mfcd42d.def, or mfcd42ud.def to match the symbols for the function generated when compiling Dbcore.cpp.

STATUS

Microsoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. This bug has been fixed in Visual Studio 97 Service Pack 3.

For more information, please see the following article in the Microsoft Knowledge Base:

170365 INFO: Visual Studio 97 Service Packs - What, Where, and Why


MORE INFORMATION

The difference between the function definitions in Dbcore.cpp and Mfc42.def, Mfcd42d.def, or Mfcd42ud.def is that the function definitions have an "A" appended to the function names in Mfc42.def, Mfcd42d.def, or Mfcd42ud.def.

These functions exist in Dbcore.cpp without the "A" appended to the function name.

Remove the "A" from the function names in question for the .def file you specify when rebuilding Mfc42.dll, Mfcd42d.dll, or Mfcd42ud.dll.

For example:

Change the following

   ?AfxThunkSQLDescribeColA@@YGFPAXGPAEFPAF2PAK22@Z @ 1507 NONAME
                

to the following:

   ?AfxThunkSQLDescribeCol@@YGFPAXGPAEFPAF2PAK22@Z @ 1507 NONAME
                

REFERENCES

See the section "Building the MFC DLL" in TN033 for information on how to rebuild the MFC DLL.

(c) Microsoft Corporation 1997, All Rights Reserved. Contributions by Isaac Varon, Microsoft Corporation.


Additional query words: AfxThunkSQL

Keywords: kbbug kbdll kbfix kbnoupdate kbvs97sp3fix KB174403